linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Anton Vorontsov <cbouatmailru@gmail.com>
To: Timur Tabi <timur@freescale.com>
Cc: linuxppc-dev@ozlabs.org, Andy Fleming <AFLEMING@freescale.com>
Subject: Re: [PATCH v5] qe: add ability to upload QE firmware
Date: Sun, 30 Dec 2007 03:20:28 +0300	[thread overview]
Message-ID: <20071230002028.GA14724@zarina> (raw)
In-Reply-To: <4776C518.6060002@freescale.com>

On Sat, Dec 29, 2007 at 04:07:20PM -0600, Timur Tabi wrote:
> Anton Vorontsov wrote:
> 
> >> +		firmware {
> >> +			id = "Soft-UART";
> >> +			extended_modes = <0 0>;
> >> +			virtual_traps = <0 0 0 0 0 0 0 0>;
> > 
> > I believe using underscores for the property name is discouraged.
> 
> Ugh, this one change would require me to repost all my patches.  Oh 
> well.  I wish someone else had noticed it before I got to version 5.

Yeah, sorry about that.

But you know it, reviewing is tedious, and only few of us are doing
reviews for the code they don't use.

I've started to use this code just now, so I reviewed it on the way.

> I'll post a new version on January 7, when I get back to the office.
> 
> >> +A Python program that creates firmware binaries from the header files normally
> >> +distributed by Freescale can be found on http://opensource.freescale.com.
> > 
> > Hm... I didn't find it there. Could you provide more specific pointer?
> 
> I'll add those files only after my patches have been applied.  The 
> layout may change between now and then, and I don't want to have to 
> repost the firmware.
> 
> >> +
> >> +	/*
> >> +	 * If we haven't checked yet, and a driver hasn't uploaded a firmware
> >> +	 * yet, then check the device tree for information.
> >> +	 */
> >> +	do {
> >         ^^^^
> > This is very unusual method of error handling. You could stick
> > to gotos and lower the indentation level.
> 
> Ok, I'll change it.  I wasn't crazy about it after I wrote it, anyway.
> 
> >> +		qe = of_find_node_by_type(NULL, "qe");
> > 
> > Please, add compatible "fsl,qe" matching, so this code could
> > work with new device trees.
> 
> Ok, but that new design was added after I posted this patch.
> 
> >> +		/* Find the 'firmware' child node */
> >> +		while ((fw = of_get_next_child(qe, fw)))
> >> +			if (strcmp(fw->name, "firmware") == 0)
> >> +				break;
> > 
> > Hmm. Maybe of_find_node_by_name? Or better by compatible.
> 
> What's wrong with looking for the firmware node inside the QE node? 
> That's the only place it can be?

Ah, I see it now. Revoking my comment.

> >> +		iprop = of_get_property(fw, "extended_modes", NULL);
> > 
> > Checking for size?
> 
> Ok.


Thanks,

-- 
Anton Vorontsov
email: cbou@mail.ru
backup email: ya-cbou@yandex.ru
irc://irc.freenode.net/bd2

  reply	other threads:[~2007-12-30  0:31 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-07 15:43 [PATCH v5] qe: add ability to upload QE firmware Timur Tabi
2007-12-12 15:17 ` Timur Tabi
2007-12-12 16:01   ` Kumar Gala
2007-12-12 22:05 ` Arnd Bergmann
2007-12-26 16:50 ` Anton Vorontsov
2007-12-29 22:07   ` Timur Tabi
2007-12-30  0:20     ` Anton Vorontsov [this message]
2008-01-07 20:05   ` Timur Tabi

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=20071230002028.GA14724@zarina \
    --to=cbouatmailru@gmail.com \
    --cc=AFLEMING@freescale.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=timur@freescale.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).