devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Grant Likely <grant.likely-s3s/WqlpOiPyB63q8FvJNQ@public.gmane.org>
To: Pantelis Antoniou
	<pantelis.antoniou-OWPKS81ov/FWk0Htik3J/w@public.gmane.org>
Cc: Joe Perches <joe-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org>,
	Andrew Morton
	<akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org>,
	Rob Herring <robherring2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	Randy Dunlap <rdunlap-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>,
	linux-doc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] of: Custom printk format specifier for device node
Date: Tue, 31 Mar 2015 21:52:31 -0700	[thread overview]
Message-ID: <20150401045231.70614C4082F@trevor.secretlab.ca> (raw)
In-Reply-To: <8421E7C5-C0D9-4C86-AA37-F6507B3BCC57-OWPKS81ov/FWk0Htik3J/w@public.gmane.org>

On Tue, 31 Mar 2015 13:03:05 +0300
, Pantelis Antoniou <pantelis.antoniou-OWPKS81ov/FWk0Htik3J/w@public.gmane.org>
 wrote:
> > +Device tree nodes:
> > +
> > +	%pOn[fnpPcCFr]
> > +
> > +	For printing device tree nodes. The optional arguments are:
> > +	    f device node full_name
> > +	    n device node name
> > +	    p device node phandle
> > +	    P device node path spec (name + @unit)
> > +	    F device node flags
> > +	    c major compatible string
> > +	    C full compatible string
> > +	Without any arguments prints full_name (same as %pOnf)
> > +	The separator when using multiple arguments is ‘:’
> ^ separator is ‘.'
> > +
> 
> > +	Examples:
> > +
> > +	%pOn	/foo/bar@0			- Node full name
> > +	%pOnf	/foo/bar@0			- Same as above
> > +	%pOnfp	/foo/bar@0:10			- Node full name + phandle
> > +	%pOnfcF	/foo/bar@0:foo,device:--P-	- Node full name +
> > +	                                          major compatible string +
> > +						  node flags
> > +							D - dynamic
> > +							d - detached
> > +							P - Populated
> > +							B - Populated bus
> > +

Thinking about this more, I'd like to suggest a different format that
gives us a nice hack on the name that makes it easy to remember:
	'%pOF[...]'
'O' still means 'object', but it is also overloaded for Open Firmware.
That still leaves %pO? for other object types.  What do you think?

g.
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2015-04-01  4:52 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-21 17:06 [PATCH] of: Custom printk format specifier for device node Pantelis Antoniou
2015-01-21 17:37 ` Joe Perches
2015-01-21 17:39   ` Pantelis Antoniou
2015-01-21 17:52     ` Joe Perches
     [not found]     ` <D84576D1-27F5-44F9-83DA-347C26F593FE-wVdstyuyKrO8r51toPun2/C9HSW9iNxf@public.gmane.org>
2015-01-21 17:59       ` Måns Rullgård
2015-01-22 20:31   ` Pantelis Antoniou
2015-03-30 19:04     ` Grant Likely
2015-03-31 10:03       ` Pantelis Antoniou
2015-03-31 17:02         ` Grant Likely
2015-03-31 17:14           ` Pantelis Antoniou
     [not found]         ` <8421E7C5-C0D9-4C86-AA37-F6507B3BCC57-OWPKS81ov/FWk0Htik3J/w@public.gmane.org>
2015-04-01  4:52           ` Grant Likely [this message]
2015-04-01  5:07             ` Joe Perches
  -- strict thread matches above, loose matches on Subject: below --
2015-01-20 14:34 Pantelis Antoniou
2015-01-20 14:47 ` Rob Herring
2015-01-20 14:52   ` Pantelis Antoniou
2015-01-20 17:59     ` Joe Perches
2015-01-20 18:03       ` Rob Herring
     [not found]       ` <1421776794.2724.1.camel-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org>
2015-01-20 18:06         ` Pantelis Antoniou
2015-01-20 18:16           ` Joe Perches
2015-01-20 15:24   ` Geert Uytterhoeven
2015-01-20 15:27     ` Pantelis Antoniou
2015-01-20 16:05       ` Måns Rullgård
2015-01-20 17:13         ` Rob Herring

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=20150401045231.70614C4082F@trevor.secretlab.ca \
    --to=grant.likely-s3s/wqlpoipyb63q8fvjnq@public.gmane.org \
    --cc=akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=joe-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org \
    --cc=linux-doc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=pantelis.antoniou-OWPKS81ov/FWk0Htik3J/w@public.gmane.org \
    --cc=rdunlap-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
    --cc=robherring2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.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).