All of lore.kernel.org
 help / color / mirror / Atom feed
From: Scott Wood <scottwood@freescale.com>
To: Russell King <rmk+lkml@arm.linux.org.uk>
Cc: trivial@kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Make platform_device_add_data accept a const pointer.
Date: Fri, 01 Dec 2006 13:37:48 -0600	[thread overview]
Message-ID: <4570848C.5040705@freescale.com> (raw)
In-Reply-To: <20061201193428.GA4055@flint.arm.linux.org.uk>

Russell King wrote:
> On Fri, Dec 01, 2006 at 12:54:47PM -0600, Scott Wood wrote:
> 
>>platform_device_add_data() makes a copy of the data that is given to it,
>>and thus the parameter can be const.  This removes a warning when data
>>from get_property() on powerpc is handed to platform_device_add_data(),
>>as get_property() returns a const pointer.
> 
> 
> Doesn't this cause a compile warning in platform.c, concerning assigning
> 'data' to struct device's non-const 'platform_data' pointer?

No, because it doesn't assign data to platform_data; it memcpy()s it (as 
stated above).

-Scott

      reply	other threads:[~2006-12-01 19:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-01 18:54 [PATCH] Make platform_device_add_data accept a const pointer Scott Wood
2006-12-01 19:34 ` Russell King
2006-12-01 19:37   ` Scott Wood [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=4570848C.5040705@freescale.com \
    --to=scottwood@freescale.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rmk+lkml@arm.linux.org.uk \
    --cc=trivial@kernel.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 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.