/* Poll all AP devices on the bus in a round robin fashion. Continue polling until bit 2^0 of the control flags is not set. If bit 2^1 of the control flags has been set arm the poll timer.  */
static void ap_poll_all(unsigned long)
/* Poll all AP devices on the bus in a round robin fashion. Continue polling until bit 2^0 of the control flags is not set. If bit 2^1 of the control flags has been set arm the poll timer.  */
static void ap_poll_all(unsigned long)
{
	unsigned long flags;
	struct ap_device *ap_dev;
	if (ap_using_interrupts())
		xchg((u8 *)ap_interrupt_indicator, 0);
	do {
		flags = 0;
		spin_lock(&ap_device_list_lock);
		list_for_each_entry(ap_dev, &ap_device_list, list) {
			spin_lock(&ap_dev->lock);
			__ap_poll_device(ap_dev, &flags);
			spin_unlock(&ap_dev->lock);
		}
		spin_unlock(&ap_device_list_lock);
	} while (flags & 1);
	if (flags & 2)
		ap_schedule_poll_timer();
}