On Sat, Dec 13, 2003 at 06:24:16PM -0500, John Homppi wrote:
> Hi Greg,
> Attached is a driver for ADU devices from Ontrak Control Systems.
> I have tested it both as a module and kernel code in 2.6.0-test11
> Testing was done on two ASUS mother boards, one with an Intel chipset
> and the other with a VIA chipset.
> 
> Note that an official USB minor device number has not been assigned.
> (I copied the Lego Tower code).
> 
> My apologies if this is the wrong time/approach for submitting the driver.

A few questions:
        - the patch is line-wrapped, and can't be applied.  Care to send
          it as a text attachment?
        - why does this need to be a kernel driver?  Can you use
          libusb/usbfs instead?
        - how many minors would you want for this driver (assuming that
          it has to be a kernel driver)?

A few very minor comments on the code:
> +     if (dev->read_buffer_primary != NULL) {
> +             kfree (dev->read_buffer_primary);
> +     }
> +     if (dev->read_buffer_secondary != NULL) {
> +             kfree (dev->read_buffer_secondary);
> +     }
> +     if (dev->interrupt_in_buffer != NULL) {
> +             kfree (dev->interrupt_in_buffer);
> +     }
> +     if (dev->interrupt_out_buffer != NULL) {
> +             kfree (dev->interrupt_out_buffer);
> +     }
> +     kfree (dev);

kfree can handle NULL as a paramater.  You don't need to check it every
time.

> +     dbg(2, "%s : leave", __func__);

I don't know if __func__ works on older versions of gcc.  I'd recommend
using __FUNCTION__ for now, as it's safer.

> +#ifdef MODULE_LICENSE
> +MODULE_LICENSE("GPL");
> +#endif

Don't put a #ifdef here, MODULE_LICENSE is always here :)


thanks,

greg k-h


-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
  • ... Dhirendra Pal Singh
  • ... 深圳市帝昊电子有限公司
  • ... 深圳市帝昊电子有限公司
  • ... admin
  • ... dave caswell
    • ... Stephen J. Gowdy
  • ... yyc
  • ... yamada1
  • ... hide tech
  • ... John Homppi
  • ... John Homppi

Reply via email to