Re: [PATCH v7 2/4] can: m_can: Rename m_can_priv to m_can_classdev

From: Dan Murphy
Date: Fri Mar 08 2019 - 07:34:19 EST


Wolfgang

On 3/8/19 4:25 AM, Wolfgang Grandegger wrote:
>
>
> Am 05.03.19 um 16:52 schrieb Dan Murphy:
>> Rename the common m_can_priv class structure to
>> m_can_classdev as this is more descriptive.
>>
>> Signed-off-by: Dan Murphy <dmurphy@xxxxxx>
>> ---
>>
>> v7 - Fixed remaining checkpatch issues, renamed priv to cdev - https://lore.kernel.org/patchwork/patch/1047219/
>>
>> v6 - No changes only rebase changes possibly can squash into the first patch -
>> https://lore.kernel.org/patchwork/patch/1042444/
>>
>> drivers/net/can/m_can/m_can.c | 524 ++++++++++++-------------
>> drivers/net/can/m_can/m_can.h | 28 +-
>> drivers/net/can/m_can/m_can_platform.c | 16 +-
>> 3 files changed, 284 insertions(+), 284 deletions(-)
>
> ...snip...
>
>> diff --git a/drivers/net/can/m_can/m_can.h b/drivers/net/can/m_can/m_can.h
>> index b60f27dd9f33..1299cc747194 100644
>> --- a/drivers/net/can/m_can/m_can.h
>> +++ b/drivers/net/can/m_can/m_can.h
>> @@ -57,19 +57,19 @@ struct mram_cfg {
>> u8 num;
>> };
>>
>> -struct m_can_priv;
>> +struct m_can_classdev;
>> struct m_can_ops {
>> /* Device specific call backs */
>> - int (*clear_interrupts)(struct m_can_priv *m_can_class);
>> - u32 (*read_reg)(struct m_can_priv *m_can_class, int reg);
>> - int (*write_reg)(struct m_can_priv *m_can_class, int reg, int val);
>> - u32 (*read_fifo)(struct m_can_priv *m_can_class, int addr_offset);
>> - int (*write_fifo)(struct m_can_priv *m_can_class, int addr_offset,
>> + int (*clear_interrupts)(struct m_can_classdev *m_can_class);
>> + u32 (*read_reg)(struct m_can_classdev *m_can_class, int reg);
>> + int (*write_reg)(struct m_can_classdev *m_can_class, int reg, int val);
>> + u32 (*read_fifo)(struct m_can_classdev *m_can_class, int addr_offset);
>> + int (*write_fifo)(struct m_can_classdev *m_can_class, int addr_offset,
>
> Could you please replace the variable name "m_can_class" with "cdev"
> here and below and in "c_can_platform.c " and "tcan4x5x.c" as well.
>

OK I will update the header

The tcan and m_can_platform source files are converted to cdev as opposed to m_can_class variable.

Dan

> Thanks,
>
> Wolfgang.
>


--
------------------
Dan Murphy