From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: David Miller <davem@davemloft.net>
Cc: sfr@canb.auug.org.au, paulus@samba.org, linuxppc-dev@ozlabs.org
Subject: Re: [PATCH][OF] Add of_device_is_available function
Date: Wed, 27 Feb 2008 08:45:37 +1100 [thread overview]
Message-ID: <1204062337.15052.160.camel@pasglop> (raw)
In-Reply-To: <20080226.133430.41760910.davem@davemloft.net>
On Tue, 2008-02-26 at 13:34 -0800, David Miller wrote:
> From: Paul Mackerras <paulus@samba.org>
> Date: Tue, 26 Feb 2008 20:04:12 +1100
>
> > It would probably be good to defend against the possibility that the
> > property isn't null-terminated (for example if its length is zero).
>
> FWIW, when I pull in the device tree on sparc I eliminate any need for
> those kinds of checks by putting a '\0' at the end of every property
> blob.
>
> I copied a lot of this code from you guys, so it wouldn't surprise
> me if ppc does this too. :-)
I doubt we do that. Properties that contain things like ranges, or "reg"
properties are expected to be of a size that is a multiple of
#size-cells/#address-cells and I'm not sure that won't break things here
or there if they suddenly get one more byte..
Or do you mean you/we are appending that-without- changing the length
field ?
Ben.
next prev parent reply other threads:[~2008-02-26 21:46 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-23 21:58 [PATCH 1/2][OF] Add of_device_is_disabled function Josh Boyer
2008-02-23 22:00 ` [PATCH 2/2][POWERPC] Ignore disabled serial ports Josh Boyer
2008-02-24 0:59 ` [PATCH 1/2][OF] Add of_device_is_disabled function Josh Boyer
2008-02-24 2:23 ` [PATCH][OF] Add of_device_is_available function Josh Boyer
2008-02-26 9:04 ` Paul Mackerras
2008-02-26 21:34 ` David Miller
2008-02-26 21:45 ` Benjamin Herrenschmidt [this message]
2008-02-26 22:44 ` David Miller
2008-02-26 22:58 ` Benjamin Herrenschmidt
2008-02-26 23:53 ` Josh Boyer
2008-02-24 2:45 ` [PATCH 1/2][OF] Add of_device_is_disabled function David Miller
2008-02-24 20:12 ` Nathan Lynch
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=1204062337.15052.160.camel@pasglop \
--to=benh@kernel.crashing.org \
--cc=davem@davemloft.net \
--cc=linuxppc-dev@ozlabs.org \
--cc=paulus@samba.org \
--cc=sfr@canb.auug.org.au \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.