From: Matt Sealey <matt@genesi-usa•com>
To: Segher Boessenkool <segher@kernel•crashing.org>
Cc: ppc-dev <linuxppc-dev@ozlabs•org>, Paul Mackerras <paulus@samba•org>
Subject: Re: [PATCH 1/2] pseries: device node status can be "ok" or "okay"
Date: Fri, 10 Aug 2007 20:23:24 +0100 [thread overview]
Message-ID: <46BCBB2C.2040408@genesi-usa.com> (raw)
In-Reply-To: <769ccd8091fc725571c5a695a70af4b9@kernel.crashing.org>
Segher Boessenkool wrote:
>> It seems that some versions of firmware will report a device
>> node status as the string "okay". As we are not expecting this
>> string, the device node will be ignored by the EEH subsystem.
>> Which means EEH will not be enabled.
>>
>> When EEH is not enabled, PCI errors will be converted into
>> Machine Check exceptions, and we'll have a very unhappy system.
>
>> - if (status && strcmp(status, "ok") != 0)
>> + if (status && strncmp(status, "ok", 2) != 0)
>> return NULL; /* ignore devices with bad status */
>
> Shouldn't you check for the two literal strings, instead of
> only matching the common prefix? Seems safer.
What are the chances that the status string is "oklahoma" or
"okeechobee" or "okinawa"?
--
Matt Sealey <matt@genesi-usa•com>
Genesi, Manager, Developer Relations
next prev parent reply other threads:[~2007-08-10 19:22 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-09 23:27 [PATCH 1/2] pseries: device node status can be "ok" or "okay" Linas Vepstas
2007-08-09 23:28 ` [PATCH 2/2] pseries: remove dead eeh video code Linas Vepstas
2007-08-10 18:06 ` [PATCH 1/2] pseries: device node status can be "ok" or "okay" Segher Boessenkool
2007-08-10 19:23 ` Matt Sealey [this message]
2007-08-10 20:17 ` Segher Boessenkool
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=46BCBB2C.2040408@genesi-usa.com \
--to=matt@genesi-usa$(echo .)com \
--cc=linuxppc-dev@ozlabs$(echo .)org \
--cc=paulus@samba$(echo .)org \
--cc=segher@kernel$(echo .)crashing.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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