static int usb_host_auto_scan(void *opaque, int bus_num, int addr,

                     int class_id, int vendor_id, int product_id,

                     const char *product_name, int speed)

{

    struct USBAutoFilter *f;

    struct USBDevice *dev;



    /* Ignore hubs */

    if (class_id == 9)

        return 0;



    for (f = usb_auto_filter; f; f = f->next) {

	if (f->bus_num >= 0 && f->bus_num != bus_num)

            continue;



	if (f->addr >= 0 && f->addr != addr)

            continue;



	if (f->vendor_id >= 0 && f->vendor_id != vendor_id)

            continue;



	if (f->product_id >= 0 && f->product_id != product_id)

            continue;



        /* We got a match */



        /* Allredy attached ? */

        if (hostdev_find(bus_num, addr))

            return 0;



        dprintf("husb: auto open: bus_num %d addr %d\n", bus_num, addr);



	dev = usb_host_device_open_addr(bus_num, addr, product_name);

    }



    return 0;

}

static int usb_host_auto_scan(void *opaque, int bus_num, int addr,

                     int class_id, int vendor_id, int product_id,

                     const char *product_name, int speed)

{

    struct USBAutoFilter *f;

    struct USBDevice *dev;



    

    if (class_id == 9)

        return 0;



    for (f = usb_auto_filter; f; f = f->next) {

	if (f->bus_num >= 0 && f->bus_num != bus_num)

            continue;



	if (f->addr >= 0 && f->addr != addr)

            continue;



	if (f->vendor_id >= 0 && f->vendor_id != vendor_id)

            continue;



	if (f->product_id >= 0 && f->product_id != product_id)

            continue;



        



        

        if (hostdev_find(bus_num, addr))

            return 0;



        dprintf("husb: auto open: bus_num %d addr %d\n", bus_num, addr);



	dev = usb_host_device_open_addr(bus_num, addr, product_name);

    }



    return 0;

}

static int FUNC_0(void *VAR_0, int VAR_1, int VAR_2,

                     int VAR_3, int VAR_4, int VAR_5,

                     const char *VAR_6, int VAR_7)

{

    struct USBAutoFilter *VAR_8;

    struct USBDevice *VAR_9;



    

    if (VAR_3 == 9)

        return 0;



    for (VAR_8 = usb_auto_filter; VAR_8; VAR_8 = VAR_8->next) {

	if (VAR_8->VAR_1 >= 0 && VAR_8->VAR_1 != VAR_1)

            continue;



	if (VAR_8->VAR_2 >= 0 && VAR_8->VAR_2 != VAR_2)

            continue;



	if (VAR_8->VAR_4 >= 0 && VAR_8->VAR_4 != VAR_4)

            continue;



	if (VAR_8->VAR_5 >= 0 && VAR_8->VAR_5 != VAR_5)

            continue;



        



        

        if (hostdev_find(VAR_1, VAR_2))

            return 0;



        dprintf("husb: auto open: VAR_1 %d VAR_2 %d\n", VAR_1, VAR_2);



	VAR_9 = usb_host_device_open_addr(VAR_1, VAR_2, VAR_6);

    }



    return 0;

}

static int FUNC_0(void *VAR_0, int VAR_1, int VAR_2,
int VAR_3, int VAR_4, int VAR_5,
const char *VAR_6, int VAR_7)
{ struct USBAutoFilter *VAR_8; struct USBDevice *VAR_9; if (VAR_3 == 9)
return 0; for (VAR_8 = usb_auto_filter; VAR_8; VAR_8 = VAR_8->next) { if (VAR_8->VAR_1 >= 0 && VAR_8->VAR_1 != VAR_1)
continue; if (VAR_8->VAR_2 >= 0 && VAR_8->VAR_2 != VAR_2)
continue; if (VAR_8->VAR_4 >= 0 && VAR_8->VAR_4 != VAR_4)
continue; if (VAR_8->VAR_5 >= 0 && VAR_8->VAR_5 != VAR_5)
continue; if (hostdev_find(VAR_1, VAR_2))
return 0; dprintf("husb: auto open: VAR_1 %d VAR_2 %d\n", VAR_1, VAR_2); VAR_9 = usb_host_device_open_addr(VAR_1, VAR_2, VAR_6); } return 0; }