RE: [PATCH 00/48] staging: comedi: avoid using comedi_board()

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

 



On Tuesday, September 09, 2014 3:26 AM, Ian Abbott wrote:
>
> The `comedi_board` inline function takes a single parameter of type
> `struct comedi_device *` and merely returns the value of the `board_ptr`
> member therein.  This is somewhat superfluous as the member can be
> accessed directly.
>
> Replace all uses of `comedi_board(dev)` with `dev->board_ptr`.
>
> Note, if there are any conflicts when applying this series, they can
> just be skipped for now and corrected later.
> 
> A subsequent patch will remove the `comedi_board` function, once there
> is nothing using it.

I would argue that the comedi_board() inline is a bit cleaner.

But, since all the goofy macros and private boardinfo access functions in
the drivers have been removed I guess this can go now. We will need
to make that sure any new drivers don't introduce new goofy macros
or access functions. The 'board(dev)->foo' ones really made the drivers
hard to read...

Reviewed-by: H Hartley Sweeten <hsweeten@xxxxxxxxxxxxxxxxxxx>

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-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