lkml.org 
[lkml]   [2021]   [Jun]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 2/4] fpga: dfl: Move DFH header register macros to linux/dfl.h
From
Date
On 21/06/2021 15.56, Tom Rix wrote:
>
> On 6/21/21 12:06 AM, Martin Hundebøll wrote:
>> From: Debarati Biswas <debaratix.biswas@intel.com>
>>
>> Device Feature List (DFL) drivers may be defined in subdirectories other
>> than drivers/fpga, and each DFL driver should have access to the Device
>> Feature Header (DFH) register, which contains revision and type
>> information. This change moves the macros specific to the DFH register
>> from drivers/fpga/dfl.h to include/linux/dfl.h.
>>
>> Signed-off-by: Debarati Biswas <debaratix.biswas@intel.com>
>> Signed-off-by: Russ Weight <russell.h.weight@intel.com>
>> Signed-off-by: Martin Hundebøll <mhu@silicom.dk>
>> ---
>>   drivers/fpga/dfl.h  | 48 +----------------------------------------
>>   include/linux/dfl.h | 52 +++++++++++++++++++++++++++++++++++++++++++++
>>   2 files changed, 53 insertions(+), 47 deletions(-)
>>
>> diff --git a/drivers/fpga/dfl.h b/drivers/fpga/dfl.h
>> index 2b82c96ba56c..6ed0353e9a99 100644
>> --- a/drivers/fpga/dfl.h
>> +++ b/drivers/fpga/dfl.h
>> @@ -17,6 +17,7 @@
>>   #include <linux/bitfield.h>
>
> bitfield.h was added to linux/dfl.h
>
> Likely both aren't needed, try removing this one.

After this patch both headers use GENMASK_ULL() and BIT_ULL(), which are both defined in linux/bits.h, so I would expect both to include that instead. A lot of the users of dfl.h uses FIELD_GET(), which is defined in linux/bitfield.h, so I would expect that to be included there instead.

I can prepare a patch to fix that up, if you like?

// Martin

\
 
 \ /
  Last update: 2021-06-23 13:44    [W:0.188 / U:0.736 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site