/* atari_register_vme_int() returns the number of a free interrupt vector for hardware with a programmable int vector (probably a VME board).  */
unsigned long atari_register_vme_int(void)
/* atari_register_vme_int() returns the number of a free interrupt vector for hardware with a programmable int vector (probably a VME board).  */
unsigned long atari_register_vme_int(void)
{
	int i;
	for (i = 0; i < 32; i++)
		if ((free_vme_vec_bitmap & (1 << i)) == 0)
			break;
	if (i == 16)
		return 0;
	free_vme_vec_bitmap |= 1 << i;
	return VME_SOURCE_BASE + i;
}