[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <MN2PR18MB2528F3206069A06618CBCCAFD3DC0@MN2PR18MB2528.namprd18.prod.outlook.com>
Date: Tue, 30 Jul 2019 03:36:16 +0000
From: Sudarsana Reddy Kalluru <skalluru@...vell.com>
To: David Miller <davem@...emloft.net>
CC: "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
Michal Kalderon <mkalderon@...vell.com>,
Ariel Elior <aelior@...vell.com>
Subject: RE: [PATCH net-next v3 2/2] qed: Add driver API for flashing the
config attributes.
> -----Original Message-----
> From: David Miller <davem@...emloft.net>
> Sent: Monday, July 29, 2019 11:34 PM
> To: Sudarsana Reddy Kalluru <skalluru@...vell.com>
> Cc: netdev@...r.kernel.org; Michal Kalderon <mkalderon@...vell.com>;
> Ariel Elior <aelior@...vell.com>
> Subject: Re: [PATCH net-next v3 2/2] qed: Add driver API for flashing the
> config attributes.
>
> From: Sudarsana Reddy Kalluru <skalluru@...vell.com>
> Date: Sat, 27 Jul 2019 18:55:49 -0700
>
> > @@ -2268,6 +2330,9 @@ static int qed_nvm_flash(struct qed_dev *cdev,
> const char *name)
> > rc = qed_nvm_flash_image_access(cdev, &data,
> > &check_resp);
> > break;
> > + case QED_NVM_FLASH_CMD_NVM_CFG_ID:
> > + rc = qed_nvm_flash_cfg_write(cdev, &data);
> > + break;
> > default:
> > DP_ERR(cdev, "Unknown command %08x\n",
> cmd_type);
>
> I don't see how any existing portable interface can cause this new code to
> actually be used.
>
> You have to explain this to me.
The API qed_nvm_flash() is used to flash the user provided data (e.g., Management FW) to the required partitions of the adapter.
- Format of the input file would be - file signature info, followed by one or more data sets.
- Each data set is represented with the header followed by its contents. Header captures info such as command name (e.g., FILE_START), data size etc., which specifies how to handle the data.
The API qed_nvm_flash() validates the user provided input file, parses the data sets and handles each accordingly. Here one of the data sets (preferably the last one) could be nvm-attributes page (with cmd-id = QED_NVM_FLASH_CMD_NVM_CHANGE).
Powered by blists - more mailing lists