Re: [PATCH 09/49] staging: comedi: adv_pci1710: use the pci id_table 'driver_data'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Mar 05, 2013 at 09:59:29AM -0700, H Hartley Sweeten wrote:
> Create an enum to the boardinfo and pass that enum in the pci_driver
> id_table as the driver_data.
> 
> Change the macro used to fill in the device table from PCI_DEVICE() to
> PCI_VDEVICE(). This allows passing the enum as the next field.
> 
> This allows removing the 'device_id' data from the boardinfo as well
> the search function that was used to locate the boardinfo for the
> PCI device.
> 
> The pci1710 and pci1710hg boards have the same vendor/device id so
> it is impossible to determine which board is actually detected. The
> boardinfo for the pci1710hg is identical to the pci1710 other than
> the analog input range information. Remove the pci1710hg information
> and #if out the range tables for that device with the define
> USE_PCI1710HG_RANGE. Modify the pci1710 boardinfo accordingly to
> use the same define to determine which range table to use. Until a
> better solution is worked out, this will allow the driver to be
> compiled to support the pci1710 (default) or pci1710hg.

This patch doesn't introduce any bugs that weren't there in the
original and actually it makes it slightly less bad.  So that's
fine.

Maybe we could take a module parameter?
We couldn't read this information from the eprom?

regards,
dan carpenter

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux