2022-10-28 16:08:01

by Frank Li

[permalink] [raw]
Subject: [PATCH v14 2/7] PCI: endpoint: pci-epf-vntb: Fix indentation of the struct epf_ntb_ctrl

From: Frank Li <[email protected]>

Indentation of the struct epf_ntb_ctrl align with other struct

Signed-off-by: Frank Li <[email protected]>
---
drivers/pci/endpoint/functions/pci-epf-vntb.c | 28 +++++++++----------
1 file changed, 14 insertions(+), 14 deletions(-)

diff --git a/drivers/pci/endpoint/functions/pci-epf-vntb.c b/drivers/pci/endpoint/functions/pci-epf-vntb.c
index c0115bcb3b5e..1863006cc36c 100644
--- a/drivers/pci/endpoint/functions/pci-epf-vntb.c
+++ b/drivers/pci/endpoint/functions/pci-epf-vntb.c
@@ -99,20 +99,20 @@ enum epf_ntb_bar {
* NTB Driver NTB Driver
*/
struct epf_ntb_ctrl {
- u32 command;
- u32 argument;
- u16 command_status;
- u16 link_status;
- u32 topology;
- u64 addr;
- u64 size;
- u32 num_mws;
- u32 reserved;
- u32 spad_offset;
- u32 spad_count;
- u32 db_entry_size;
- u32 db_data[MAX_DB_COUNT];
- u32 db_offset[MAX_DB_COUNT];
+ u32 command;
+ u32 argument;
+ u16 command_status;
+ u16 link_status;
+ u32 topology;
+ u64 addr;
+ u64 size;
+ u32 num_mws;
+ u32 reserved;
+ u32 spad_offset;
+ u32 spad_count;
+ u32 db_entry_size;
+ u32 db_data[MAX_DB_COUNT];
+ u32 db_offset[MAX_DB_COUNT];
} __packed;

struct epf_ntb {
--
2.34.1



2022-11-01 12:24:08

by Manivannan Sadhasivam

[permalink] [raw]
Subject: Re: [PATCH v14 2/7] PCI: endpoint: pci-epf-vntb: Fix indentation of the struct epf_ntb_ctrl

On Fri, Oct 28, 2022 at 11:56:58AM -0400, Frank Li wrote:
> From: Frank Li <[email protected]>
>
> Indentation of the struct epf_ntb_ctrl align with other struct
>

"Align the indentation of struct epf_ntb_ctrl with other structs in the driver"

> Signed-off-by: Frank Li <[email protected]>
> ---
> drivers/pci/endpoint/functions/pci-epf-vntb.c | 28 +++++++++----------
> 1 file changed, 14 insertions(+), 14 deletions(-)
>
> diff --git a/drivers/pci/endpoint/functions/pci-epf-vntb.c b/drivers/pci/endpoint/functions/pci-epf-vntb.c
> index c0115bcb3b5e..1863006cc36c 100644
> --- a/drivers/pci/endpoint/functions/pci-epf-vntb.c
> +++ b/drivers/pci/endpoint/functions/pci-epf-vntb.c
> @@ -99,20 +99,20 @@ enum epf_ntb_bar {
> * NTB Driver NTB Driver
> */
> struct epf_ntb_ctrl {
> - u32 command;
> - u32 argument;
> - u16 command_status;
> - u16 link_status;
> - u32 topology;
> - u64 addr;
> - u64 size;
> - u32 num_mws;
> - u32 reserved;
> - u32 spad_offset;
> - u32 spad_count;
> - u32 db_entry_size;
> - u32 db_data[MAX_DB_COUNT];
> - u32 db_offset[MAX_DB_COUNT];
> + u32 command;
> + u32 argument;
> + u16 command_status;
> + u16 link_status;
> + u32 topology;
> + u64 addr;
> + u64 size;
> + u32 num_mws;
> + u32 reserved;
> + u32 spad_offset;
> + u32 spad_count;
> + u32 db_entry_size;
> + u32 db_data[MAX_DB_COUNT];
> + u32 db_offset[MAX_DB_COUNT];

General question: Don't we need to take care of endianess here?

Thanks,
Mani

> } __packed;
>
> struct epf_ntb {
> --
> 2.34.1
>

--
மணிவண்ணன் சதாசிவம்

2022-11-01 16:19:16

by Frank Li

[permalink] [raw]
Subject: RE: [EXT] Re: [PATCH v14 2/7] PCI: endpoint: pci-epf-vntb: Fix indentation of the struct epf_ntb_ctrl



> -----Original Message-----
> From: Manivannan Sadhasivam <[email protected]>
> Sent: Tuesday, November 1, 2022 6:56 AM
> To: Frank Li <[email protected]>
> Cc: [email protected]; [email protected]; [email protected];
> [email protected]; [email protected]; [email protected];
> [email protected]; [email protected]; [email protected];
> [email protected]; [email protected]
> Subject: [EXT] Re: [PATCH v14 2/7] PCI: endpoint: pci-epf-vntb: Fix
> indentation of the struct epf_ntb_ctrl
>
> Caution: EXT Email
>
> On Fri, Oct 28, 2022 at 11:56:58AM -0400, Frank Li wrote:
> > From: Frank Li <[email protected]>
> >
> > Indentation of the struct epf_ntb_ctrl align with other struct
> >
>
> "Align the indentation of struct epf_ntb_ctrl with other structs in the driver"
>
> > Signed-off-by: Frank Li <[email protected]>
> > ---
> > drivers/pci/endpoint/functions/pci-epf-vntb.c | 28 +++++++++----------
> > 1 file changed, 14 insertions(+), 14 deletions(-)
> >
> > diff --git a/drivers/pci/endpoint/functions/pci-epf-vntb.c
> b/drivers/pci/endpoint/functions/pci-epf-vntb.c
> > index c0115bcb3b5e..1863006cc36c 100644
> > --- a/drivers/pci/endpoint/functions/pci-epf-vntb.c
> > +++ b/drivers/pci/endpoint/functions/pci-epf-vntb.c
> > @@ -99,20 +99,20 @@ enum epf_ntb_bar {
> > * NTB Driver NTB Driver
> > */
> > struct epf_ntb_ctrl {
> > - u32 command;
> > - u32 argument;
> > - u16 command_status;
> > - u16 link_status;
> > - u32 topology;
> > - u64 addr;
> > - u64 size;
> > - u32 num_mws;
> > - u32 reserved;
> > - u32 spad_offset;
> > - u32 spad_count;
> > - u32 db_entry_size;
> > - u32 db_data[MAX_DB_COUNT];
> > - u32 db_offset[MAX_DB_COUNT];
> > + u32 command;
> > + u32 argument;
> > + u16 command_status;
> > + u16 link_status;
> > + u32 topology;
> > + u64 addr;
> > + u64 size;
> > + u32 num_mws;
> > + u32 reserved;
> > + u32 spad_offset;
> > + u32 spad_count;
> > + u32 db_entry_size;
> > + u32 db_data[MAX_DB_COUNT];
> > + u32 db_offset[MAX_DB_COUNT];
>
> General question: Don't we need to take care of endianess here?

[Frank Li] you are right. But it is out of scope of this patch.
We can add it later.

>
> Thanks,
> Mani
>
> > } __packed;
> >
> > struct epf_ntb {
> > --
> > 2.34.1
> >
>
> --
> மணிவண்ணன் சதாசிவம்