public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stefan Roese <sr@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/1] at91: Add command to control up to 3 GPIO LEDs from the console
Date: Fri, 8 May 2009 08:21:05 +0200	[thread overview]
Message-ID: <200905080821.05239.sr@denx.de> (raw)
In-Reply-To: <4A03C2E9.1010501@esd.eu>

Hi Daniel,

On Friday 08 May 2009, Daniel Gorsulowski wrote:
> > I suggest to use something like this here:
> >
> > 	led_nr = simple_strtoul(argv[1], NULL, 10);
> > 	if (led_nr > CONFIG_LED_MAX) {
> > 		printf ("Usage:\n%s\n", cmdtp->usage);
> > 		return 1;
> > 	}
> >
> > 	if (strcmp(argv[2], "off") == 0) {
> > 		on = 1;
> > 	} else if (strcmp(argv[2], "on") == 0) {
> > 		on = 0;
> > 	} else {
> > 		printf ("Usage:\n%s\n", cmdtp->usage);
> > 		return 1;
> > 	}
> >
> > 	user_led(led_nr, on);
> >
> > No ugly #ifdef's in this case. What do you think?
> >
> > Best regards,
> > Stefan
>
> I agree with you.

Good. :)

> Please give me some days, to implement your basic approaches.
> I've many other things to do and it's not that easy (for me)
> to create a tidy patch.

Sure. Take your time. 

Thanks.

Best regards,
Stefan

=====================================================================
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: office at denx.de
=====================================================================

  reply	other threads:[~2009-05-08  6:21 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-06 14:21 [U-Boot] [PATCH 1/1] at91: Add command to control up to 3 GPIO LEDs from the console Daniel Gorsulowski
2009-05-06 20:37 ` Wolfgang Denk
2009-05-06 20:40   ` Mike Frysinger
2009-05-07  6:01   ` Daniel Gorsulowski
2009-05-07  7:32     ` Wolfgang Denk
2009-05-08  5:37       ` Daniel Gorsulowski
2009-05-07  6:31 ` Stefan Roese
2009-05-08  5:28   ` Daniel Gorsulowski
2009-05-08  6:21     ` Stefan Roese [this message]
2009-05-14  8:49       ` Daniel Gorsulowski

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=200905080821.05239.sr@denx.de \
    --to=sr@denx.de \
    --cc=u-boot@lists.denx.de \
    /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