public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Lan Chunhe <b25806@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/2] fdt: Add a fdt_set_node_status function
Date: Mon, 15 Aug 2011 11:03:54 +0800	[thread overview]
Message-ID: <op.vz8issa2z91x4h@localhost.localdomain> (raw)
In-Reply-To: <CAOZdJXXzgwmqRVbojQ0J6zxr7BriY_CoU9PCFNDxMudAns4n_w@mail.gmail.com>

On Mon, 15 Aug 2011 08:08:04 +0800, Tabi Timur-B04825  
<B04825@freescale.com> wrote:

> On Thu, Aug 11, 2011 at 11:18 PM, Chunhe Lan <Chunhe.Lan@freescale.com>  
> wrote:
>
>> +/*
>> + * Sets the specified node's status to the value contained in "status".
>> + * If the first character of the specified path is "/" then we use
>> + * alias as a path. Otherwise, we look for an alias of that name.
>> + */
>> +void fdt_set_node_status(void *fdt, const char *alias, const char  
>> *status)
>> +{
>> +       const char *path = fdt_get_alias(fdt, alias);
>> +
>> +       if (!path)
>> +               path = alias;
>> +
>> +       do_fixup_by_path(fdt, path, "status", status, strlen(status) +  
>> 1, 1);
>> +}
>
> If you're going to take some internal code and post it upstream, you
> should at least use the latest version of that code.  The latest
> version of this function has this comment:
>
> /*
>  * Given an alias or a path for a node, set the status of that node.
>  *
>  * If 'alias' is not a valid alias, then it is treated as a full path to  
> the
>  * node.  No error checking is performed.
>  *
>  * This function is normally called to set the status for a virtual MDIO  
> node.
>  */
>
> However, since you're moving this function to fdt_support, the last
> sentence should be dropped.

    OK.
    Thanks.

>> +++ b/include/fdt_support.h
>> @@ -2,6 +2,8 @@
>>  * (C) Copyright 2007
>>  * Gerald Van Baren, Custom IDEAS, vanbaren at cideas.com
>>  *
>> + * Copyright (C) 2011 Freescale Semiconductor, Inc.
>> + *
>
> Like Scott said, adding a single function prototype is not sufficient
> for a new copyright claim.  You have to add a significant amount of
> original code in order to add a new copyright line.

    Thanks for your comments.

    -Jack Lan

      reply	other threads:[~2011-08-15  3:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-12  3:18 [U-Boot] [PATCH 1/2] fdt: Add a fdt_set_node_status function Chunhe Lan
2011-08-12 16:24 ` Scott Wood
2011-08-15  3:40   ` Lan Chunhe
2011-08-15 18:12     ` Scott Wood
2011-08-16  7:24       ` Lan Chunhe
2011-08-15  0:08 ` Tabi Timur-B04825
2011-08-15  3:03   ` Lan Chunhe [this message]

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=op.vz8issa2z91x4h@localhost.localdomain \
    --to=b25806@freescale.com \
    --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