linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
Cc: "Mauro Carvalho Chehab" <mchehab@redhat.com>,
	"Randy Dunlap" <rdunlap@infradead.org>,
	"Ezequiel García" <elezegarcia@gmail.com>,
	"Stephen Rothwell" <sfr@canb.auug.org.au>,
	linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-media <linux-media@vger.kernel.org>,
	linux-kbuild@vger.kernel.org
Subject: Re: Splitting stk1160-ac97 as a module (Re: linux-next: Tree for May 1 (media/usb/stk1160))
Date: Sat, 4 May 2013 21:59:50 +0200	[thread overview]
Message-ID: <20130504195950.GA3254@free.fr> (raw)
In-Reply-To: <20130504172142.GA21656@localhost>

Ezequiel, All,

On Sat, May 04, 2013 at 02:21:44PM -0300, Ezequiel Garcia wrote:
> I'm trying to split the ac97 support into a separate module.
> So far I've managed to do this with two different approaches,
> but both of them are broken in some way :-(
> 
> Couple questions:
> 
> 1. Is it possible to force two symbols to be both built-in (=y) or both
> modules (=m)? This would make one of my solutions work.

If they are always the same value, there is no need to have two symbols
in the first place.

However, given the original problem from this thread, if what you meant
was to have the second symbol either 'n' or the same as the first symbol,
ie. the following table:

    A:  n   m   m   y   y
    B:  n   n   m   n   y

Then the closest I came up with is:

    config MODULES
        bool "Modules"
    
    config A
        tristate "A"
    
    config B_dummy
        bool "B"
        depends on A
    
    config B
        tristate
        default m if A=m && B_dummy
        default y if A=y && B_dummy

where B_dummy is not used outside of Kconfig, and only A and B are the
symbols of interest (eg. to build the drivers).

Otherwise, I was not able to get the desired behviour with only the A
and B symbols.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

  reply	other threads:[~2013-05-04 19:59 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-01  8:37 linux-next: Tree for May 1 Stephen Rothwell
2013-05-01 11:22 ` Sedat Dilek
2013-05-01 17:59 ` linux-next: Tree for May 1 (media/usb/stk1160) Randy Dunlap
2013-05-01 19:28   ` Yann E. MORIN
2013-05-01 19:32     ` Randy Dunlap
2013-05-01 19:58     ` David Rientjes
2013-05-01 20:23       ` Randy Dunlap
2013-05-01 20:40         ` David Rientjes
2013-05-01 20:53         ` Yann E. MORIN
2013-05-01 20:58           ` Randy Dunlap
2013-05-02 14:52   ` Mauro Carvalho Chehab
2013-05-02 21:23     ` Randy Dunlap
2013-05-04 17:21     ` Splitting stk1160-ac97 as a module (Re: linux-next: Tree for May 1 (media/usb/stk1160)) Ezequiel Garcia
2013-05-04 19:59       ` Yann E. MORIN [this message]
2013-05-06 13:11         ` Ezequiel Garcia
2013-05-01 18:44 ` [PATCH -next] hid: fix hid-steelseries kconfig/build Randy Dunlap
2013-05-01 19:27   ` simon
2013-05-01 19:39     ` Randy Dunlap
2013-05-01 20:32       ` simon
2013-05-02  6:27   ` [PATCH] HID: hid-steelseries fix led class build issue Simon Wood
2013-05-02 21:50     ` Randy Dunlap
2013-05-02 21:58       ` David Rientjes
2013-05-03  1:43         ` [PATCH-V2] " Simon Wood
2013-05-03  8:27           ` Jiri Kosina
2013-05-02  6:30   ` [PATCH] " Simon Wood
2013-05-01 19:18 ` [PATCH -next] power: fix lp8788-charger kconfig & build Randy Dunlap
2013-05-01 23:04   ` Kim, Milo
2013-05-03  4:22     ` Anton Vorontsov
2013-05-01 19:27 ` [PATCH -next] staging: sep: fix driver build and kconfig Randy Dunlap
2013-05-02  7:37 ` linux-next: Tree for May 1 ZX
2013-05-02  7:46   ` Hannes Reinecke

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=20130504195950.GA3254@free.fr \
    --to=yann.morin.1998@free.fr \
    --cc=elezegarcia@gmail.com \
    --cc=ezequiel.garcia@free-electrons.com \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=mchehab@redhat.com \
    --cc=rdunlap@infradead.org \
    --cc=sfr@canb.auug.org.au \
    /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).