ChangeSet 1.1673.8.28, 2004/03/26 11:24:29-08:00, oliver@neukum.org

[PATCH] USB: fix hfc_usb sleeping in irq

you are using GFP_KERNEL in irq and __devinit with hotpluggable code.

      - use proper GFP flags
      - kill __devinit


 drivers/isdn/hisax/hfc_usb.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)


diff -Nru a/drivers/isdn/hisax/hfc_usb.c b/drivers/isdn/hisax/hfc_usb.c
--- a/drivers/isdn/hisax/hfc_usb.c	Wed Apr 14 14:37:58 2004
+++ b/drivers/isdn/hisax/hfc_usb.c	Wed Apr 14 14:37:58 2004
@@ -262,7 +262,7 @@
 		hfc->ctrl_urb->transfer_buffer_length = 0;
 		hfc->ctrl_write.wIndex = hfc->ctrl_buff[hfc->ctrl_out_idx].hfc_reg;
 		hfc->ctrl_write.wValue = hfc->ctrl_buff[hfc->ctrl_out_idx].reg_val;
-		err = usb_submit_urb(hfc->ctrl_urb, GFP_KERNEL);	/* start transfer */
+		err = usb_submit_urb(hfc->ctrl_urb, GFP_ATOMIC);	/* start transfer */
 		printk(KERN_DEBUG "ctrl_start_transfer: submit %d\n", err);
 	}
 }				/* ctrl_start_transfer */
@@ -754,7 +754,7 @@
 			}
         }
 
-		errcode = usb_submit_urb(urb, GFP_KERNEL);
+		errcode = usb_submit_urb(urb, GFP_ATOMIC);
 		if(errcode < 0)
 		{
 			printk(KERN_INFO "HFC-USB: error submitting ISO URB: %i \n",  errcode);
@@ -821,7 +821,7 @@
 		fill_isoc_urb(urb, fifo->hfc->dev, fifo->pipe,context_iso_urb->buffer, num_isoc_packets,
 			fifo->usb_packet_maxlen, fifo->intervall, rx_iso_complete, urb->context);
 
-		errcode = usb_submit_urb(urb, GFP_KERNEL);
+		errcode = usb_submit_urb(urb, GFP_ATOMIC);
 		if(errcode < 0)
 		{
 			printk(KERN_INFO "HFC-USB: error submitting ISO URB: %i \n",  errcode);
@@ -1345,7 +1345,7 @@
 /*************************************************/
 /* function called to probe a new plugged device */
 /*************************************************/
-static int __devinit hfc_usb_probe(struct usb_interface *intf, const struct usb_device_id *id)
+static int hfc_usb_probe(struct usb_interface *intf, const struct usb_device_id *id)
 {
 	struct usb_device *dev= interface_to_usbdev(intf);
 	hfcusb_data *context;
