From: NeilBrown <neilb@suse.de>
To: Pawel Baldysiak <pawel.baldysiak@intel.com>
Cc: linux-raid@vger.kernel.org, artur.paszkiewicz@intel.com
Subject: Re: [PATCH] IMSM-orom: make sure, that device list is supported
Date: Wed, 4 Mar 2015 16:00:52 +1100 [thread overview]
Message-ID: <20150304160052.4a64461f@notabene.brown> (raw)
In-Reply-To: <20150227144550.9215.35006.stgit@gklab-154-222.intel.com>
[-- Attachment #1: Type: text/plain, Size: 1219 bytes --]
On Fri, 27 Feb 2015 15:45:50 +0100 Pawel Baldysiak
<pawel.baldysiak@intel.com> wrote:
> Devices list in PCI Data Structure is supported only in
> 3 and above revision. Make sure that this is checked.
>
> Signed-off-by: Pawel Baldysiak <pawel.baldysiak@intel.com>
> ---
> platform-intel.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/platform-intel.c b/platform-intel.c
> index 37274da..c6a28e8 100644
> --- a/platform-intel.c
> +++ b/platform-intel.c
> @@ -227,6 +227,8 @@ struct pciExpDataStructFormat {
> __u16 vendorID;
> __u16 deviceID;
> __u16 devListOffset;
> + __u16 pciDataStructLen;
> + __u8 pciDataStructRev;
> } __attribute__ ((packed));
>
> static struct orom_entry oroms[SYS_DEV_MAX];
> @@ -323,7 +325,8 @@ static int scan(const void *start, const void *end, const void *data)
>
> const struct imsm_orom *orom = add_orom(imsm_mem);
>
> - if (ptr->devListOffset) {
> + /* only PciDataStructure with revision 3 and above supports devices list. */
> + if (ptr->pciDataStructRev >= 3 && ptr->devListOffset) {
> const __u16 *dev_list = (void *)ptr + ptr->devListOffset;
> int i;
>
Applied, thanks.
NeilBrown
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 811 bytes --]
prev parent reply other threads:[~2015-03-04 5:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-27 14:45 [PATCH] IMSM-orom: make sure, that device list is supported Pawel Baldysiak
2015-03-04 5:00 ` NeilBrown [this message]
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=20150304160052.4a64461f@notabene.brown \
--to=neilb@suse.de \
--cc=artur.paszkiewicz@intel.com \
--cc=linux-raid@vger.kernel.org \
--cc=pawel.baldysiak@intel.com \
/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).