From: Chen Yu <yu.c.chen@intel.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org,
"Rafael J. Wysocki" <rafael@kernel.org>,
Len Brown <len.brown@intel.com>,
Dan Williams <dan.j.williams@intel.com>,
Andy Shevchenko <andriy.shevchenko@intel.com>,
Aubrey Li <aubrey.li@intel.com>, Ashok Raj <ashok.raj@intel.com>,
Mike Rapoport <rppt@kernel.org>, Ard Biesheuvel <ardb@kernel.org>,
Jonathan Corbet <corbet@lwn.net>,
Hans de Goede <hdegoede@redhat.com>,
Maximilian Luz <luzmaximilian@gmail.com>,
Alexander Graf <graf@amazon.com>,
Jarkko Sakkinen <jarkko@kernel.org>,
Hannes Reinecke <hare@suse.de>,
Ioana Ciornei <ioana.ciornei@nxp.com>,
Jiri Slaby <jirislaby@kernel.org>,
Andra Paraschiv <andraprs@amazon.com>,
Randy Dunlap <rdunlap@infradead.org>,
Ben Widawsky <ben.widawsky@intel.com>,
linux-doc@vger.kernel.org
Subject: Re: [PATCH v2 3/5] drivers/acpi: Introduce Platform Firmware Runtime Update device driver
Date: Wed, 15 Sep 2021 17:03:57 +0800 [thread overview]
Message-ID: <20210915090357.GA282742@chenyu-desktop> (raw)
In-Reply-To: <YUBZM1vnZ3LjfUKc@kroah.com>
Hi Greg,
thank you very much for your comments,
On Tue, Sep 14, 2021 at 10:11:31AM +0200, Greg Kroah-Hartman wrote:
> On Tue, Sep 14, 2021 at 03:58:41PM +0800, Chen Yu wrote:
> > +enum start_action {
> > + START_STAGE,
> > + START_ACTIVATE,
> > + START_STAGE_ACTIVATE,
> > +};
> > +
> > +enum dsm_status {
> > + DSM_SUCCEED,
> > + DSM_FUNC_NOT_SUPPORT,
> > + DSM_INVAL_INPUT,
> > + DSM_HARDWARE_ERR,
> > + DSM_RETRY_SUGGESTED,
> > + DSM_UNKNOWN,
> > + DSM_FUNC_SPEC_ERR,
> > +};
> > +
> > +struct update_cap_info {
> > + enum dsm_status status;
> > + int update_cap;
> > +
> > + uuid_t code_type;
> > + int fw_version;
> > + int code_rt_version;
> > +
> > + uuid_t drv_type;
> > + int drv_rt_version;
> > + int drv_svn;
> > +
> > + uuid_t platform_id;
> > + uuid_t oem_id;
> > +
> > + char oem_info[];
>
> Please use valid types for structures that cross the user/kernel
> boundry.
>
Okay, I'll switch them into __u prefixed one.
> > +};
> > +
> > +struct com_buf_info {
> > + enum dsm_status status;
> > + enum dsm_status ext_status;
> > + unsigned long addr_lo;
> > + unsigned long addr_hi;
> > + int buf_size;
> > +};
>
> Same here.
>
Okay, I'll fix them.
> > +
> > +struct updated_result {
> > + enum dsm_status status;
> > + enum dsm_status ext_status;
> > + unsigned long low_auth_time;
> > + unsigned long high_auth_time;
> > + unsigned long low_exec_time;
> > + unsigned long high_exec_time;
>
> And same here.
>
> And these are very odd structure names that you are adding to the
> "global" namespace. Please make them have a prefix for your driver so
> that people know what they belong to. "updated_result" is way too
> generic.
>
Okay, added the driver name prefix in next version.
thanks,
Chenyu
next prev parent reply other threads:[~2021-09-15 8:58 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-14 7:24 [PATCH v2 0/5] Introduce Platform Firmware Runtime Update and Telemetry drivers Chen Yu
2021-09-14 7:28 ` [PATCH v2 1/5] Documentation: Introduce Platform Firmware Runtime Update documentation Chen Yu
2021-09-14 7:30 ` [PATCH v2 2/5] efi: Introduce EFI_FIRMWARE_MANAGEMENT_CAPSULE_HEADER and corresponding structures Chen Yu
2021-09-14 7:58 ` [PATCH v2 3/5] drivers/acpi: Introduce Platform Firmware Runtime Update device driver Chen Yu
2021-09-14 8:11 ` Greg Kroah-Hartman
2021-09-15 9:03 ` Chen Yu [this message]
2021-09-14 8:11 ` [PATCH v2 4/5] drivers/acpi: Introduce Platform Firmware Runtime Update Telemetry Chen Yu
2021-09-14 8:12 ` [PATCH v2 5/5] selftests/pfru: add test for Platform Firmware Runtime Update and Telemetry Chen Yu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210915090357.GA282742@chenyu-desktop \
--to=yu.c.chen@intel.com \
--cc=andraprs@amazon.com \
--cc=andriy.shevchenko@intel.com \
--cc=ardb@kernel.org \
--cc=ashok.raj@intel.com \
--cc=aubrey.li@intel.com \
--cc=ben.widawsky@intel.com \
--cc=corbet@lwn.net \
--cc=dan.j.williams@intel.com \
--cc=graf@amazon.com \
--cc=gregkh@linuxfoundation.org \
--cc=hare@suse.de \
--cc=hdegoede@redhat.com \
--cc=ioana.ciornei@nxp.com \
--cc=jarkko@kernel.org \
--cc=jirislaby@kernel.org \
--cc=len.brown@intel.com \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luzmaximilian@gmail.com \
--cc=rafael@kernel.org \
--cc=rdunlap@infradead.org \
--cc=rppt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).