backports.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* How to use backports?
@ 2018-05-15 19:41 Patrick Doyle
  2018-05-15 20:04 ` Johannes Berg
  0 siblings, 1 reply; 8+ messages in thread
From: Patrick Doyle @ 2018-05-15 19:41 UTC (permalink / raw)
  To: backports

Please forgive my ignorance.  I would like to use the backports tool
to backport a driver from a fork of linux-next to my (vendor's) custom
4.9 kernel.

>From reading https://backports.wiki.kernel.org/index.php/Documentation/integration
it would appear that I should be able to do something vaguely like:

$ ./gentree.py --integrate --clean --gitdebug ../linux-ath-erstrom
../buildroot/build/linux-custom

But, the first time I tried that, I received the following error:

You need to have installed: spatch
Try installing the package: coccinelle

So:

$ sudo apt install coccinelle

and try again, only to get this error:

You need to have installed: spatch >= 1.0.6
Try installing the package: coccinelle

So now I am trying to compile coccinelle from source and that is failing:

cp: cannot stat '/usr/lib/ocaml/parmap/parmap.cmx': No such file or directory
Makefile:620: recipe for target 'ocaml/parmap.cmi' failed

It appears that the version of libparmap-ocaml-dev I installed on my
Ubuntu 16.04 workstation does not include parmap.cmx.  (It includes
parmap.cmxa and parmap.cmxs, but not parmap.cmx).

Or, perhaps I'm off on completely the wrong tangent here.

So, first questions first...
If I want to port a driver from the latest linux-ath-erstrom source
tree to my custom 4.9 source tree, is backports and gentree.py the
right way to go?

Should I reasonably expect gentree to run on a 16.04 LTS Ubuntu?  If
so, what dependencies should I install?

Or am I going about this the wrong way?

I'm stuck, and would appreciate any help anybody can give me.

Thanks in advance.

--wpd
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: How to use backports?
  2018-05-15 19:41 How to use backports? Patrick Doyle
@ 2018-05-15 20:04 ` Johannes Berg
  2018-05-15 20:26   ` Patrick Doyle
  0 siblings, 1 reply; 8+ messages in thread
From: Johannes Berg @ 2018-05-15 20:04 UTC (permalink / raw)
  To: Patrick Doyle, backports

Hi Patrick,

> From reading https://backports.wiki.kernel.org/index.php/Documentation/integration
> it would appear that I should be able to do something vaguely like:
> 
> $ ./gentree.py --integrate --clean --gitdebug ../linux-ath-erstrom
> ../buildroot/build/linux-custom

In theory yes. I can't really recommend --integrate, it's untested. I
may remove it entirely since nobody is maintaining it.

> You need to have installed: spatch >= 1.0.6
> Try installing the package: coccinelle

Indeed. There was actually a very recent commit (latest commit) that
would make this require only an earlier version. Reverting that may be
easier for you.

> So now I am trying to compile coccinelle from source and that is failing:
> 
> cp: cannot stat '/usr/lib/ocaml/parmap/parmap.cmx': No such file or directory
> Makefile:620: recipe for target 'ocaml/parmap.cmi' failed
> 
> It appears that the version of libparmap-ocaml-dev I installed on my
> Ubuntu 16.04 workstation does not include parmap.cmx.  (It includes
> parmap.cmxa and parmap.cmxs, but not parmap.cmx).
> 
> Or, perhaps I'm off on completely the wrong tangent here.

That I can't really say. I guess you could ask the coccinelle mailing
list about it.

> So, first questions first...
> If I want to port a driver from the latest linux-ath-erstrom source
> tree to my custom 4.9 source tree, is backports and gentree.py the
> right way to go?

Yes, that sounds reasonable. I don't know what "linux-ath-erstrom" is,
but if it's reasonably close to upstream now it should be OK.

> Should I reasonably expect gentree to run on a 16.04 LTS Ubuntu?  If
> so, what dependencies should I install?

No idea, sorry.

johannes

--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: How to use backports?
  2018-05-15 20:04 ` Johannes Berg
@ 2018-05-15 20:26   ` Patrick Doyle
  2018-05-15 20:30     ` Johannes Berg
  0 siblings, 1 reply; 8+ messages in thread
From: Patrick Doyle @ 2018-05-15 20:26 UTC (permalink / raw)
  To: Johannes Berg; +Cc: backports

Hello Johannes,
Thank you for your quick reply.
On Tue, May 15, 2018 at 4:04 PM, Johannes Berg
<johannes@sipsolutions.net> wrote:
>> From reading https://backports.wiki.kernel.org/index.php/Documentation/integration
>> it would appear that I should be able to do something vaguely like:
>>
>> $ ./gentree.py --integrate --clean --gitdebug ../linux-ath-erstrom
>> ../buildroot/build/linux-custom
>
> In theory yes. I can't really recommend --integrate, it's untested. I
> may remove it entirely since nobody is maintaining it.
So, that's all that I see documented at
https://backports.wiki.kernel.org/index.php/Documentation.  That page
describes 2 workflows: "kernel integration mode" and  "package
releases mode".  The link to the "kernel integration mode"
documentation describes how to run gentree.py.  The link to the
"package releases mode" documentation just says to run "make
menuconfig" without giving any details of how to connect the newer
source tree to an older revision.

It turns out, for my project, I would prefer to use the "kernel
integration mode", since I would really like to turn off loadable
modules (not needed for my space-constrained embedded target).  But if
the "too hard" LED comes on, I can let that go.

Anyway... am I looking in the wrong place for documentation?  Should I
be looking elsewhere?

How do folks use backports anyway?

>
>> You need to have installed: spatch >= 1.0.6
>> Try installing the package: coccinelle
>
> Indeed. There was actually a very recent commit (latest commit) that
> would make this require only an earlier version. Reverting that may be
> easier for you.
OK, I'll try that.  Thanks.
(that just failed to find a
../buildroot/build/linux-custom/backports/Kconfig... which smells a
little like bitrot to me).


>> So, first questions first...
>> Should I reasonably expect gentree to run on a 16.04 LTS Ubuntu?  If
>> so, what dependencies should I install?
>
> No idea, sorry.
>
> johannes
>
If folks don't tend to use this tool on Ubuntu LTS releases, what
version of Linux do you use it on?  What is known to work?

--wpd
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: How to use backports?
  2018-05-15 20:26   ` Patrick Doyle
@ 2018-05-15 20:30     ` Johannes Berg
  2018-05-15 22:19       ` Steve deRosier
  0 siblings, 1 reply; 8+ messages in thread
From: Johannes Berg @ 2018-05-15 20:30 UTC (permalink / raw)
  To: Patrick Doyle; +Cc: backports

On Tue, 2018-05-15 at 16:26 -0400, Patrick Doyle wrote:
> It turns out, for my project, I would prefer to use the "kernel
> integration mode", since I would really like to turn off loadable
> modules (not needed for my space-constrained embedded target).  But if
> the "too hard" LED comes on, I can let that go.

You can try it I guess.

For the "loadable module" mode you just remove "--integrate" from the
command line and use a new (empty) directory for the output - the system
then leaves there a setup where you can use "make menuconfig" etc. for
out-of-tree module compilation.

> Anyway... am I looking in the wrong place for documentation?  Should I
> be looking elsewhere?

No, that seems about right, but nobody's maintaining it much.

> How do folks use backports anyway?

We use it with some of the devel/ scripts to make a git tree that
follows the upstream kernel tree, but that just uses gentree internally.

> OK, I'll try that.  Thanks.
> (that just failed to find a
> ../buildroot/build/linux-custom/backports/Kconfig... which smells a
> little like bitrot to me).

That's ... a bit strange, that's the file it should be creating there
for the integration?

> If folks don't tend to use this tool on Ubuntu LTS releases, what
> version of Linux do you use it on?  What is known to work?

I usually use one of Debian/testing or Fedora (currently F27 while I
wait for some things I can't upgrade).

We do run it one some kind of Ubuntu LTS at work, but I suspect they
also installed spatch by hand, no idea how though.

johannes
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: How to use backports?
  2018-05-15 20:30     ` Johannes Berg
@ 2018-05-15 22:19       ` Steve deRosier
  2018-05-16 13:24         ` Patrick Doyle
  0 siblings, 1 reply; 8+ messages in thread
From: Steve deRosier @ 2018-05-15 22:19 UTC (permalink / raw)
  To: Johannes Berg; +Cc: wpdster, backports

On Tue, May 15, 2018 at 1:31 PM Johannes Berg <johannes@sipsolutions.net>
wrote:
> > If folks don't tend to use this tool on Ubuntu LTS releases, what
> > version of Linux do you use it on?  What is known to work?

> I usually use one of Debian/testing or Fedora (currently F27 while I
> wait for some things I can't upgrade).

> We do run it one some kind of Ubuntu LTS at work, but I suspect they
> also installed spatch by hand, no idea how though.


I usually run Ubuntu LTS (server, not desktop) for most of my Linux build
systems. Like Johannes mentioned, I build coccinelle from source.  While
I'm aware of the >= 1.0.6 patch that went in a few days ago, I haven't
built with anything that modern yet. Fact is, since changing jobs recently,
I'm not using backports as much as I used to since I'm stuck working on a
vendor driver.

Anyway, sorry I'm not that much help - I just wanted to answer your "does
anyone use Ubuntu for backports building" question.  Answer is yes, it's
possible to do so.

- Steve
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: How to use backports?
  2018-05-15 22:19       ` Steve deRosier
@ 2018-05-16 13:24         ` Patrick Doyle
  2018-05-16 13:26           ` Johannes Berg
  0 siblings, 1 reply; 8+ messages in thread
From: Patrick Doyle @ 2018-05-16 13:24 UTC (permalink / raw)
  To: Steve deRosier; +Cc: Johannes Berg, backports

On Tue, May 15, 2018 at 6:19 PM, Steve deRosier <derosier@gmail.com> wrote:
> On Tue, May 15, 2018 at 1:31 PM Johannes Berg <johannes@sipsolutions.net>
> wrote:
> I usually run Ubuntu LTS (server, not desktop) for most of my Linux build
> systems. Like Johannes mentioned, I build coccinelle from source.  While
> I'm aware of the >= 1.0.6 patch that went in a few days ago, I haven't
> built with anything that modern yet. Fact is, since changing jobs recently,
> I'm not using backports as much as I used to since I'm stuck working on a
> vendor driver.
>
> Anyway, sorry I'm not that much help - I just wanted to answer your "does
> anyone use Ubuntu for backports building" question.  Answer is yes, it's
> possible to do so.
Thanks Steve.  That is a help.
I was just trying to decide if I should return from interrupt, or
declare a fault :-)

When too many things started going wrong (didn't have coccinelle
installed, have never heard of it, have no idea what it is, apt-get
installed it, was informed it was too old, git cloned it, installed
dependencies for building it, found that it would not compile, even
with the dependencies installed), the "too hard" LED came on and I
figured I should ask some questions.  I'll go find somebody I can ask
about compiling coccinelle (whatever that is) on Ubuntu 16.04, figure
out what's going on there, and return from interrupt now.

Then I'll either figure out what's going on with the --integrate flag
in backports, or decide to live with a loadable module.

Thanks for the help.

--wpd
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: How to use backports?
  2018-05-16 13:24         ` Patrick Doyle
@ 2018-05-16 13:26           ` Johannes Berg
  2018-05-16 13:28             ` Patrick Doyle
  0 siblings, 1 reply; 8+ messages in thread
From: Johannes Berg @ 2018-05-16 13:26 UTC (permalink / raw)
  To: Patrick Doyle, Steve deRosier; +Cc: backports

On Wed, 2018-05-16 at 09:24 -0400, Patrick Doyle wrote:
> I'll go find somebody I can ask
> about compiling coccinelle (whatever that is) on Ubuntu 16.04, figure
> out what's going on there, and return from interrupt now.

This is the mailing list: cocci@systeme.lip6.fr

johannes
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: How to use backports?
  2018-05-16 13:26           ` Johannes Berg
@ 2018-05-16 13:28             ` Patrick Doyle
  0 siblings, 0 replies; 8+ messages in thread
From: Patrick Doyle @ 2018-05-16 13:28 UTC (permalink / raw)
  To: Johannes Berg; +Cc: Steve deRosier, backports

On Wed, May 16, 2018 at 9:26 AM, Johannes Berg
<johannes@sipsolutions.net> wrote:
> On Wed, 2018-05-16 at 09:24 -0400, Patrick Doyle wrote:
>> I'll go find somebody I can ask
>> about compiling coccinelle (whatever that is) on Ubuntu 16.04, figure
>> out what's going on there, and return from interrupt now.
>
> This is the mailing list: cocci@systeme.lip6.fr
Excellent!
Thank you.

--wpd
--
To unsubscribe from this list: send the line "unsubscribe backports" in

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2018-05-16 13:28 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-15 19:41 How to use backports? Patrick Doyle
2018-05-15 20:04 ` Johannes Berg
2018-05-15 20:26   ` Patrick Doyle
2018-05-15 20:30     ` Johannes Berg
2018-05-15 22:19       ` Steve deRosier
2018-05-16 13:24         ` Patrick Doyle
2018-05-16 13:26           ` Johannes Berg
2018-05-16 13:28             ` Patrick Doyle

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).