linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chen Gang <gang.chen.5i5j@gmail.com>
To: Greg KH <gregkh@linuxfoundation.org>
Cc: rjw@rjwysocki.net, pavel@ucw.cz, len.brown@intel.com,
	ulf.hansson@linaro.org, khilman@linaro.org,
	geert+renesas@glider.be, tomasz.figa@gmail.com, richard@nod.at,
	linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drivers: base: power: domain: Use 'pm_cpu_data' instead of 'cpu_data' for compiling break
Date: Sun, 05 Oct 2014 10:11:05 +0800	[thread overview]
Message-ID: <5430A8B9.6040003@gmail.com> (raw)
In-Reply-To: <20141005012301.GA17655@kroah.com>

On 10/5/14 9:23, Greg KH wrote:
> On Sun, Oct 05, 2014 at 09:13:09AM +0800, Chen Gang wrote:
>> On 10/5/14 0:00, Greg KH wrote:
>>> On Sat, Oct 04, 2014 at 10:19:50PM +0800, Chen Gang wrote:
>>>> 'cpu_data' is too common to be already used by some architectures (e.g.
>>>> um, m32r, and mn10300), so need use 'pm_cpu_data' instead of, or cause
>>>> compiling break. The related error (with allmodconfig under um):
>>>>
>>>>     CC      drivers/base/platform.o
>>>>   In file included from ./arch/x86/um/asm/processor.h:31:0,
>>>>                    from ./arch/um/include/asm/uaccess.h:16,
>>>>                    from ./arch/um/include/asm/thread_info.h:13,
>>>>                    from include/linux/thread_info.h:54,
>>>>                    from include/asm-generic/current.h:4,
>>>>                    from arch/um/include/generated/asm/current.h:1,
>>>>                    from include/linux/mutex.h:13,
>>>>                    from include/linux/kernfs.h:13,
>>>>                    from include/linux/sysfs.h:15,
>>>>                    from include/linux/kobject.h:21,
>>>>                    from include/linux/device.h:17,
>>>>                    from include/linux/platform_device.h:14,
>>>>                    from drivers/base/platform.c:14:
>>>>   ./arch/um/include/asm/processor-generic.h:107:19: error: expected identifier or '(' before '&' token
>>>>    #define cpu_data (&boot_cpu_data)
>>>>                      ^
>>>>   include/linux/pm_domain.h:74:23: note: in expansion of macro 'cpu_data'
>>>>     struct gpd_cpu_data *cpu_data;
>>>>                        ^
>>>>
>>>> Also need notice about 80 columns boundary.
>>>
>>> I don't object to this change at all, but it could be easier to solve
>>> this by fixing up 'cpu_data' to be named something a bit less "generic"?
>>> What does x86 use for this data type?
>>>
>>
>> It is for some kinds of arm cpu (I let this patch pass arm s3c600
>> def_config building).  Other architectures did not use it, at present.
> 
> So why not change the name for these archs that have such a generic name
> to something not so generic?
> 

All the code are really generic, I don't know whether it will be used
under other architectures in the future (I guess, it will, or it need
not be put to "drivers/base/power/" and "include/linux").

At present, it is not used by other architectures, but it already has
negative effect with other architectures (I found it during compiling
um architecture).

So for me, this issue is not only within arm itself, but also in common
drivers.


Thanks
-- 
Chen Gang

Open, share, and attitude like air, water, and life which God blessed

  reply	other threads:[~2014-10-05  2:11 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-04 14:19 [PATCH] drivers: base: power: domain: Use 'pm_cpu_data' instead of 'cpu_data' for compiling break Chen Gang
2014-10-04 14:20 ` Chen Gang
2014-10-04 16:00 ` Greg KH
2014-10-05  1:13   ` Chen Gang
2014-10-05  1:23     ` Greg KH
2014-10-05  2:11       ` Chen Gang [this message]
2014-10-05  1:31     ` Chen Gang
2014-10-05  2:42   ` Randy Dunlap
2014-10-05  2:57     ` Chen Gang
2014-10-05 21:32 ` Rafael J. Wysocki
2014-10-05 23:55   ` Chen Gang

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=5430A8B9.6040003@gmail.com \
    --to=gang.chen.5i5j@gmail.com \
    --cc=geert+renesas@glider.be \
    --cc=gregkh@linuxfoundation.org \
    --cc=khilman@linaro.org \
    --cc=len.brown@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=pavel@ucw.cz \
    --cc=richard@nod.at \
    --cc=rjw@rjwysocki.net \
    --cc=tomasz.figa@gmail.com \
    --cc=ulf.hansson@linaro.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;
as well as URLs for NNTP newsgroup(s).