linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Nicolas Pitre <nico@fluxnic.net>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Greg KH <gregkh@linuxfoundation.org>,
	David Brown <davidb@codeaurora.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Arnd Bergmann <arnd@arndb.de>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [GIT PATCH] char/misc patches for 3.10-rc1
Date: Mon, 29 Apr 2013 16:45:05 -0400 (EDT)	[thread overview]
Message-ID: <alpine.LFD.2.03.1304291605070.17372@syhkavp.arg> (raw)
In-Reply-To: <CA+55aFzLtBwsvVrnT2DrUOU+eYrQ5eiKeamRb4Y5+-TVgbuM5Q@mail.gmail.com>

On Mon, 29 Apr 2013, Linus Torvalds wrote:

> The "explanations" for why it should be in drivers/ is this mindless drivel:
> 
> On Tue, Feb 22 2011, Daniel Walker wrote:
> > On Tue, 2011-02-22 at 12:47 -0800, Dima Zavin wrote:
> >
> >> What is the problem leaving it under arch/arm/mach-msm?
> >
> > Because it's a driver.
> 
> Seriously. That's the *ONLY* explanation given.

This certainly sucks as an answer.

> WTF? That's a singularly *bad* reason for moving things to "drivers".

Agreed.

> And I'm calling the ARM people out on this idiocy. Arnd and Nico -
> stop encouraging this kind of crap. Move things to drivers only once
> there is actual reason for it. If it's some proprierary single-SoC
> thing, it can damn well stay away from other people. And it definitely
> shouldn't mess up autocomplete in some core location.

All I wish to add to what Arnd already stated is this:

We ought to gather drivers together according to their _purpose_.  
Especially if they provide some generic functionality via a common API 
to be used by the rest of the kernel.  In some cases that API just begs 
to be created and commonalities factored out from individual drivers, 
which also warrants a move to drivers/.

Of course the cpufreq drivers, or even the cpuidle drivers, are awfully 
platform specific, or even proprietary single-SoC in many cases.  But 
the interface they register into and the services they provide are 
common, and it is far easier for someone maintaining the cpuidle 
infrastructure to improve the interface and avoid conflicts by having 
all the related drivers at the same place. .  It even helps next driver 
author look for better examples than only the last SoC they worked with.

However this is a design goal, not a hard rule.  If a piece of code has 
no interface commonality with anything else then it is indeed not worth 
the hassle.


Nicolas

      parent reply	other threads:[~2013-04-29 20:45 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-29 16:21 [GIT PATCH] char/misc patches for 3.10-rc1 Greg KH
2013-04-29 18:28 ` Linus Torvalds
2013-04-29 18:38   ` Greg KH
2013-04-29 18:55     ` Linus Torvalds
2013-04-29 19:02       ` Linus Torvalds
2013-04-29 19:15       ` Linus Torvalds
2013-04-29 19:54         ` Arnd Bergmann
2013-04-29 20:12           ` Linus Torvalds
2013-04-29 20:50             ` Arnd Bergmann
2013-04-29 21:13               ` Linus Torvalds
2013-04-29 21:22                 ` Arnd Bergmann
2013-05-01 16:12               ` Mark Brown
2013-04-29 21:08             ` David Brown
2013-04-29 21:16               ` Arnd Bergmann
2013-05-01 16:13                 ` Mark Brown
2013-05-02 20:53                   ` David Brown
2013-05-03  8:06                     ` Mark Brown
2013-04-29 21:18               ` Linus Torvalds
2013-04-29 21:29                 ` Arnd Bergmann
2013-04-29 22:00                 ` MFD: move ssbi driver into drivers/mfd Arnd Bergmann
2013-04-29 22:10                   ` Greg KH
2013-04-29 22:48                   ` Nicolas Pitre
2013-04-30  0:00                   ` David Brown
2013-04-30 10:18                   ` Samuel Ortiz
2013-04-30 10:26                     ` Arnd Bergmann
2013-05-16  9:49                   ` Samuel Ortiz
2013-04-29 20:45         ` Nicolas Pitre [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=alpine.LFD.2.03.1304291605070.17372@syhkavp.arg \
    --to=nico@fluxnic.net \
    --cc=akpm@linux-foundation.org \
    --cc=arnd@arndb.de \
    --cc=davidb@codeaurora.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.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).