mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Kumar Gala <galak@kernel.crashing.org>
To: Greg KH <greg@kroah.com>
Cc: linux-kernel@vger.kernel.org, linuxppc-dev@ozlabs.org
Subject: Re: [PATCH v3 1/3] driver core: Add ability for arch code to setup pdev_archdata
Date: Thu, 7 Jul 2011 08:55:44 -0500	[thread overview]
Message-ID: <597354F4-D1D4-4BC0-9251-FDDC31B1E2A1@kernel.crashing.org> (raw)
In-Reply-To: <20110701220900.GA28971@kroah.com>


On Jul 1, 2011, at 5:09 PM, Greg KH wrote:

> On Thu, Jun 23, 2011 at 06:33:57AM -0500, Kumar Gala wrote:
>> On some architectures we need to setup pdev_archdata before we add the
>> device.  Waiting til a bus_notifier is too late since we might need the
>> pdev_archdata in the bus notifier.  One example is setting up of dma_mask
>> pointers such that it can be used in a bus_notifier.
>> 
>> We add noop version of arch_setup_pdev_archdata() in
>> <asm-generic/platform_device.h> and allow the arch code to override with
>> access the full definitions of struct device, struct platform_device, and
>> struct pdev_archdata.
> 
> Isn't there some way to use "weak" symbols to keep us from having to
> create this .h file in every single arch and then if the arch wants to
> define it, it does so?
> 
> That should make this patch simpler, right?
> 
> thanks,
> 
> greg k-h

Changing to weak should be doable if we are ok with the additional function call always happening.

- k


  reply	other threads:[~2011-07-07 13:56 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-22 12:02 [PATCH " Kumar Gala
2011-06-22 12:02 ` [PATCH 2/3] powerpc: implement arch_setup_pdev_archdata Kumar Gala
2011-06-22 12:02   ` [PATCH 3/3] powerpc: Dont require a dma_ops struct to set dma mask Kumar Gala
2011-06-22 17:53     ` Scott Wood
2011-06-22 14:37 ` [PATCH 1/3] driver core: Add ability for arch code to setup pdev_archdata Mike Frysinger
2011-06-22 15:09 ` [PATCH v2 " Kumar Gala
2011-06-22 17:52   ` Scott Wood
2011-06-23 11:33 ` [PATCH v3 " Kumar Gala
2011-06-23 11:33   ` [PATCH v3 2/3] powerpc: implement arch_setup_pdev_archdata Kumar Gala
2011-06-23 11:33     ` [PATCH v3 3/3] powerpc: Dont require a dma_ops struct to set dma mask Kumar Gala
2011-07-01 22:09   ` [PATCH v3 1/3] driver core: Add ability for arch code to setup pdev_archdata Greg KH
2011-07-07 13:55     ` Kumar Gala [this message]
2011-07-07 14:11       ` Greg KH
2011-07-08  4:03         ` Kumar Gala

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=597354F4-D1D4-4BC0-9251-FDDC31B1E2A1@kernel.crashing.org \
    --to=galak@kernel.crashing.org \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@ozlabs.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

all inboxes | Powered by JetHome®