Message ID | 20120521.050300.1434374935904126254.davem@davemloft.net |
---|---|
State | Accepted |
Delegated to: | David Miller |
Headers | show |
On Mon, May 21, 2012 at 2:03 AM, David Miller <davem@davemloft.net> wrote: > > There is going to be a merge conflict between the commit in the > net-next tree that adds the Sparc BPF JIT, and the one in here which > adds arch/sparc/Kbuild. It should be quite easy to resolve. Ok, so that had a very obvious resolution, and a "cleaner, but scarier" version. I picked the cleaner but scarier one - the one that should make the BFP JIT be built when you do "make arch/sparc" by putting the net thing into the new arch/sparc/Kbuild file. I did minimal testing with "make ARCH=sparc" without actually *building* anything, and in the process also fixed the fact that you should not select HAVE_BPF_JIT unless networking is enabled (crappy interface - maybe that "if NET" part really should be in the HAVE_BPF_JIT rules, not in all the architectures?) But I do not have (nor do I really want) a sparc cross-compile environment, so maybe my "cleaner" resolution is just garbage. Can you please check the end result? So if I broke something, please call me names and tell me to not try to think too much, and worry my little brain with things I don't understand. The thing is pushed out, so you can see what I did. Linus -- To unsubscribe from this list: send the line "unsubscribe sparclinux" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Mon, May 21, 2012 at 10:37:23AM -0700, Linus Torvalds wrote: > On Mon, May 21, 2012 at 2:03 AM, David Miller <davem@davemloft.net> wrote: > > > > There is going to be a merge conflict between the commit in the > > net-next tree that adds the Sparc BPF JIT, and the one in here which > > adds arch/sparc/Kbuild. It should be quite easy to resolve. > > Ok, so that had a very obvious resolution, and a "cleaner, but scarier" version. > > I picked the cleaner but scarier one - the one that should make the > BFP JIT be built when you do "make arch/sparc" by putting the net > thing into the new arch/sparc/Kbuild file. OK. > > I did minimal testing with "make ARCH=sparc" without actually > *building* anything, and in the process also fixed the fact that you > should not select HAVE_BPF_JIT unless networking is enabled (crappy > interface - maybe that "if NET" part really should be in the > HAVE_BPF_JIT rules, not in all the architectures?) HAVE_BPF_JIT is only used to make the BPF_JIT prompt visible. And BPF_JIT depends on NET. So the "if NET" part in the select is redundant but not strictly wrong. Sam -- To unsubscribe from this list: send the line "unsubscribe sparclinux" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Mon, May 21, 2012 at 11:24 AM, Sam Ravnborg <sam@ravnborg.org> wrote: > > So the "if NET" part in the select is redundant but not strictly wrong. It's not redundant. Try doing a "make ARCH=sparc allnoconfig" without it. It will warn. I didn't bother looking at *why* it warns, but all other architectures have the "if NET" part. Linus -- To unsubscribe from this list: send the line "unsubscribe sparclinux" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Mon, May 21, 2012 at 11:28 AM, Linus Torvalds <torvalds@linux-foundation.org> wrote: > > I didn't bother looking at *why* it warns, but all other architectures > have the "if NET" part. Ok, I looked now, and it's because the definition of HAVE_BPF_JIT is inside the "if NET" thing. So if NET isn't enabled, then HAVE_BPF_JIT doesn't really *exist* as an option. Doing a "select" on it is thus not a good idea. I bet you could just move the two lines config HAVE_BPF_JIT bool up to the top of net/Kconfig (so that HAVE_BPF_JIT is available unconditionally), and then remove all the "if NET" from the four architectures that support it. Linus -- To unsubscribe from this list: send the line "unsubscribe sparclinux" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Mon, May 21, 2012 at 11:28:58AM -0700, Linus Torvalds wrote: > On Mon, May 21, 2012 at 11:24 AM, Sam Ravnborg <sam@ravnborg.org> wrote: > > > > So the "if NET" part in the select is redundant but not strictly wrong. > > It's not redundant. > > Try doing a "make ARCH=sparc allnoconfig" without it. It will warn. > > I didn't bother looking at *why* it warns, but all other architectures > have the "if NET" part. I see. This is because HAVE_BPF_JIT depends on NET, so kconfig warns if you select HAVE_BPF_JIT without NET enabled. The correct fix is obviously to move HAVE_BPF_JIT so it does not depend on NET. Sprinkling "if NET" all over is the wrong fix. Sam -- To unsubscribe from this list: send the line "unsubscribe sparclinux" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html