All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] backport: allow compilation with Ubuntu's 3.13
@ 2015-05-19 13:42 Emmanuel Grumbach
  2015-05-20  8:27 ` Johannes Berg
  2015-05-25 21:52 ` Hauke Mehrtens
  0 siblings, 2 replies; 16+ messages in thread
From: Emmanuel Grumbach @ 2015-05-19 13:42 UTC (permalink / raw)
  To: backports; +Cc: Emmanuel Grumbach

Canonical backported:

Author: Or Gerlitz <ogerlitz@mellanox.com>
Date:   Mon Jan 20 13:59:19 2014 +0200

    net: Add GRO support for UDP encapsulating protocols

This is commit 2da204a8f67fbe25816cbce8cc8551f03d5b951a in their
tree.
Cope with that.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
---
Touch compiled only. And I don't really know how the UTS thing goes :)
---
 backport/backport-include/linux/netdevice.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/backport/backport-include/linux/netdevice.h b/backport/backport-include/linux/netdevice.h
index bb3fefb..61ac95c 100644
--- a/backport/backport-include/linux/netdevice.h
+++ b/backport/backport-include/linux/netdevice.h
@@ -81,6 +81,7 @@ static inline void dev_consume_skb_any(struct sk_buff *skb)
 	dev_kfree_skb_any(skb);
 }
 
+#if (LINUX_VERSION_CODE == KERNEL_VERSION(3,13,11) && UTS_UBUNTU_RELEASE_ABI < 24)
 struct pcpu_sw_netstats {
 	u64     rx_packets;
 	u64     rx_bytes;
@@ -88,6 +89,7 @@ struct pcpu_sw_netstats {
 	u64     tx_bytes;
 	struct u64_stats_sync   syncp;
 };
+#endif
 
 #define netdev_tstats(dev)	((struct pcpu_sw_netstats *)dev->ml_priv)
 #define netdev_assign_tstats(dev, e)	dev->ml_priv = (e);
-- 
2.1.4


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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-19 13:42 [PATCH] backport: allow compilation with Ubuntu's 3.13 Emmanuel Grumbach
@ 2015-05-20  8:27 ` Johannes Berg
  2015-05-20  8:31   ` Grumbach, Emmanuel
  2015-05-25 21:52 ` Hauke Mehrtens
  1 sibling, 1 reply; 16+ messages in thread
From: Johannes Berg @ 2015-05-20  8:27 UTC (permalink / raw)
  To: Emmanuel Grumbach; +Cc: backports

On Tue, 2015-05-19 at 16:42 +0300, Emmanuel Grumbach wrote:

> +#if (LINUX_VERSION_CODE == KERNEL_VERSION(3,13,11) && UTS_UBUNTU_RELEASE_ABI < 24)

Now that I look at this again, I'm confused - shouldn't this whole thing
have a ! in front?

johannes


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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20  8:27 ` Johannes Berg
@ 2015-05-20  8:31   ` Grumbach, Emmanuel
  2015-05-20  8:34     ` Johannes Berg
  2015-05-20  8:36     ` Luca Coelho
  0 siblings, 2 replies; 16+ messages in thread
From: Grumbach, Emmanuel @ 2015-05-20  8:31 UTC (permalink / raw)
  To: johannes; +Cc: backports

T24gV2VkLCAyMDE1LTA1LTIwIGF0IDEwOjI3ICswMjAwLCBKb2hhbm5lcyBCZXJnIHdyb3RlOg0K
PiBPbiBUdWUsIDIwMTUtMDUtMTkgYXQgMTY6NDIgKzAzMDAsIEVtbWFudWVsIEdydW1iYWNoIHdy
b3RlOg0KPiANCj4gPiArI2lmIChMSU5VWF9WRVJTSU9OX0NPREUgPT0gS0VSTkVMX1ZFUlNJT04o
MywxMywxMSkgJiYgVVRTX1VCVU5UVV9SRUxFQVNFX0FCSSA8IDI0KQ0KPiANCj4gTm93IHRoYXQg
SSBsb29rIGF0IHRoaXMgYWdhaW4sIEknbSBjb25mdXNlZCAtIHNob3VsZG4ndCB0aGlzIHdob2xl
IHRoaW5nDQo+IGhhdmUgYSAhIGluIGZyb250Pw0KPiANCg0Kd2h5Pw0KSSBuZWVkIHRoaXMgZGVm
aW5pdGlvbiBvbmx5IGZvciBVYnVudHUgcmVsZWFzZXMgdGhhdCBhcmUgYmVsb3cgMjQuDQpDYW5v
bmljYWwgcG9ydGVkIHRoYXQgc3RhcnRpbmcgMjQuDQpXaGF0IGFtIEkgbWlzc2luZz8NCg==

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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20  8:31   ` Grumbach, Emmanuel
@ 2015-05-20  8:34     ` Johannes Berg
  2015-05-20  8:39       ` Grumbach, Emmanuel
  2015-05-20  8:36     ` Luca Coelho
  1 sibling, 1 reply; 16+ messages in thread
From: Johannes Berg @ 2015-05-20  8:34 UTC (permalink / raw)
  To: Grumbach, Emmanuel; +Cc: backports

On Wed, 2015-05-20 at 08:31 +0000, Grumbach, Emmanuel wrote:
> On Wed, 2015-05-20 at 10:27 +0200, Johannes Berg wrote:
> > On Tue, 2015-05-19 at 16:42 +0300, Emmanuel Grumbach wrote:
> > 
> > > +#if (LINUX_VERSION_CODE == KERNEL_VERSION(3,13,11) && UTS_UBUNTU_RELEASE_ABI < 24)
> > 
> > Now that I look at this again, I'm confused - shouldn't this whole thing
> > have a ! in front?
> > 
> 
> why?
> I need this definition only for Ubuntu releases that are below 24.
> Canonical ported that starting 24.
> What am I missing?

But every mainline kernel, say 3.10, also needs it. Also Ubuntu with
3.10, for example.

johannes


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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20  8:31   ` Grumbach, Emmanuel
  2015-05-20  8:34     ` Johannes Berg
@ 2015-05-20  8:36     ` Luca Coelho
  1 sibling, 0 replies; 16+ messages in thread
From: Luca Coelho @ 2015-05-20  8:36 UTC (permalink / raw)
  To: Grumbach, Emmanuel; +Cc: johannes, backports

On Wed, 2015-05-20 at 08:31 +0000, Grumbach, Emmanuel wrote:
> On Wed, 2015-05-20 at 10:27 +0200, Johannes Berg wrote:
> > On Tue, 2015-05-19 at 16:42 +0300, Emmanuel Grumbach wrote:
> > 
> > > +#if (LINUX_VERSION_CODE == KERNEL_VERSION(3,13,11) && UTS_UBUNTU_RELEASE_ABI < 24)
> > 
> > Now that I look at this again, I'm confused - shouldn't this whole thing
> > have a ! in front?
> > 
> 
> why?
> I need this definition only for Ubuntu releases that are below 24.
> Canonical ported that starting 24.
> What am I missing?

At least the code as is doesn't work for me on Ubuntu 12.04 with 3.10
kernel...

--
Luca


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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20  8:34     ` Johannes Berg
@ 2015-05-20  8:39       ` Grumbach, Emmanuel
  2015-05-20 15:30         ` Larry Finger
  0 siblings, 1 reply; 16+ messages in thread
From: Grumbach, Emmanuel @ 2015-05-20  8:39 UTC (permalink / raw)
  To: johannes; +Cc: backports

T24gV2VkLCAyMDE1LTA1LTIwIGF0IDEwOjM0ICswMjAwLCBKb2hhbm5lcyBCZXJnIHdyb3RlOg0K
PiBPbiBXZWQsIDIwMTUtMDUtMjAgYXQgMDg6MzEgKzAwMDAsIEdydW1iYWNoLCBFbW1hbnVlbCB3
cm90ZToNCj4gPiBPbiBXZWQsIDIwMTUtMDUtMjAgYXQgMTA6MjcgKzAyMDAsIEpvaGFubmVzIEJl
cmcgd3JvdGU6DQo+ID4gPiBPbiBUdWUsIDIwMTUtMDUtMTkgYXQgMTY6NDIgKzAzMDAsIEVtbWFu
dWVsIEdydW1iYWNoIHdyb3RlOg0KPiA+ID4gDQo+ID4gPiA+ICsjaWYgKExJTlVYX1ZFUlNJT05f
Q09ERSA9PSBLRVJORUxfVkVSU0lPTigzLDEzLDExKSAmJiBVVFNfVUJVTlRVX1JFTEVBU0VfQUJJ
IDwgMjQpDQo+ID4gPiANCj4gPiA+IE5vdyB0aGF0IEkgbG9vayBhdCB0aGlzIGFnYWluLCBJJ20g
Y29uZnVzZWQgLSBzaG91bGRuJ3QgdGhpcyB3aG9sZSB0aGluZw0KPiA+ID4gaGF2ZSBhICEgaW4g
ZnJvbnQ/DQo+ID4gPiANCj4gPiANCj4gPiB3aHk/DQo+ID4gSSBuZWVkIHRoaXMgZGVmaW5pdGlv
biBvbmx5IGZvciBVYnVudHUgcmVsZWFzZXMgdGhhdCBhcmUgYmVsb3cgMjQuDQo+ID4gQ2Fub25p
Y2FsIHBvcnRlZCB0aGF0IHN0YXJ0aW5nIDI0Lg0KPiA+IFdoYXQgYW0gSSBtaXNzaW5nPw0KPiAN
Cj4gQnV0IGV2ZXJ5IG1haW5saW5lIGtlcm5lbCwgc2F5IDMuMTAsIGFsc28gbmVlZHMgaXQuIEFs
c28gVWJ1bnR1IHdpdGgNCj4gMy4xMCwgZm9yIGV4YW1wbGUuDQo+IA0KDQpZb3UgYXJlIHJpZ2h0
IG9idmlvdXNseS4NCg==

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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20  8:39       ` Grumbach, Emmanuel
@ 2015-05-20 15:30         ` Larry Finger
  2015-05-20 16:42           ` Grumbach, Emmanuel
  2015-06-08 18:58           ` Luis R. Rodriguez
  0 siblings, 2 replies; 16+ messages in thread
From: Larry Finger @ 2015-05-20 15:30 UTC (permalink / raw)
  To: Grumbach, Emmanuel, johannes; +Cc: backports

On 05/20/2015 03:39 AM, Grumbach, Emmanuel wrote:
> On Wed, 2015-05-20 at 10:34 +0200, Johannes Berg wrote:
>> On Wed, 2015-05-20 at 08:31 +0000, Grumbach, Emmanuel wrote:
>>> On Wed, 2015-05-20 at 10:27 +0200, Johannes Berg wrote:
>>>> On Tue, 2015-05-19 at 16:42 +0300, Emmanuel Grumbach wrote:
>>>>
>>>>> +#if (LINUX_VERSION_CODE == KERNEL_VERSION(3,13,11) && UTS_UBUNTU_RELEASE_ABI < 24)
>>>>
>>>> Now that I look at this again, I'm confused - shouldn't this whole thing
>>>> have a ! in front?
>>>>
>>>
>>> why?
>>> I need this definition only for Ubuntu releases that are below 24.
>>> Canonical ported that starting 24.
>>> What am I missing?
>>
>> But every mainline kernel, say 3.10, also needs it. Also Ubuntu with
>> 3.10, for example.
>>
>
> You are right obviously.

What happens if the user is not running a Ubuntu kernel and 
UTS_UBUNTU_RELEASE_ABI is undefined?

I am really pissed off about Ubuntu's backporting API changes so that testing 
LINUX_VERSION_CODE is no longer sufficient. In fact when someone complains the 
one of the out-of-kernel drivers that I maintain does not build with kernel X.Y, 
I check that version out in mainline, build the driver to make sure the problem 
is not mine, and then tell them to complain to their vendor. I no longer fix 
those problems. I think RHEL is also doing the same kind of thing - at least I 
did get one complaint about a build problem that seemed to be due to an API 
backport. Where do we stop?

Larry





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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20 15:30         ` Larry Finger
@ 2015-05-20 16:42           ` Grumbach, Emmanuel
  2015-05-20 16:53             ` Larry Finger
  2015-06-08 18:58           ` Luis R. Rodriguez
  1 sibling, 1 reply; 16+ messages in thread
From: Grumbach, Emmanuel @ 2015-05-20 16:42 UTC (permalink / raw)
  To: Larry.Finger; +Cc: backports, johannes

T24gV2VkLCAyMDE1LTA1LTIwIGF0IDEwOjMwIC0wNTAwLCBMYXJyeSBGaW5nZXIgd3JvdGU6DQo+
IE9uIDA1LzIwLzIwMTUgMDM6MzkgQU0sIEdydW1iYWNoLCBFbW1hbnVlbCB3cm90ZToNCj4gPiBP
biBXZWQsIDIwMTUtMDUtMjAgYXQgMTA6MzQgKzAyMDAsIEpvaGFubmVzIEJlcmcgd3JvdGU6DQo+
ID4+IE9uIFdlZCwgMjAxNS0wNS0yMCBhdCAwODozMSArMDAwMCwgR3J1bWJhY2gsIEVtbWFudWVs
IHdyb3RlOg0KPiA+Pj4gT24gV2VkLCAyMDE1LTA1LTIwIGF0IDEwOjI3ICswMjAwLCBKb2hhbm5l
cyBCZXJnIHdyb3RlOg0KPiA+Pj4+IE9uIFR1ZSwgMjAxNS0wNS0xOSBhdCAxNjo0MiArMDMwMCwg
RW1tYW51ZWwgR3J1bWJhY2ggd3JvdGU6DQo+ID4+Pj4NCj4gPj4+Pj4gKyNpZiAoTElOVVhfVkVS
U0lPTl9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hdmUgdGhlbSBtb3JlIGludm9sdmVkIGluIGJhY2twb3J0IHRv
IGZpeCBpdCB0aGVtc2VsdmVzPw0KQW5kIGV4cGxhaW4gdG8gdGhlbSBob3cgaW1wb3J0YW50IGl0
IGlzIHRvIGJlIGFibGUgdG8gcnVuIGJhY2twb3J0IG9uDQp0b3Agb2YgYWxsIHRoZWlyIHNoaXBw
ZWQga2VybmVscz8NCg0KPiANCj4gTGFycnkNCj4gDQo+IA0KPiANCj4gDQoNCg==

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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20 16:42           ` Grumbach, Emmanuel
@ 2015-05-20 16:53             ` Larry Finger
  2015-05-20 16:55               ` Grumbach, Emmanuel
  2015-05-20 16:59               ` Johannes Berg
  0 siblings, 2 replies; 16+ messages in thread
From: Larry Finger @ 2015-05-20 16:53 UTC (permalink / raw)
  To: Grumbach, Emmanuel; +Cc: backports, johannes

On 05/20/2015 11:42 AM, Grumbach, Emmanuel wrote:
>
> Good question... I don't know. OTOH, distros don't really support
> backport. You can't really blame them if they break backport, why should
> they care?
> I agree. It is annoying. We can try to convince them, but I don't think
> that saying "you are all wrong" is the right path. Maybe we should try
> to have them more involved in backport to fix it themselves?
> And explain to them how important it is to be able to run backport on
> top of all their shipped kernels?

Supporting backport would be a first step, but that won't help all of the rtl8* 
repos that I have at GitHub. Most of those do not have drivers in the kernel, 
thus the users are dependent on that kind of external repo; however, I do not 
have any desire to find out what macro needs to be tested so that these drivers 
will build on distros that I do not use.

I guess I should report a bug to whatever disto breaks my driver and request 
that they fix it. I already know how much that will help :)

Larry



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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20 16:53             ` Larry Finger
@ 2015-05-20 16:55               ` Grumbach, Emmanuel
  2015-05-20 16:59               ` Johannes Berg
  1 sibling, 0 replies; 16+ messages in thread
From: Grumbach, Emmanuel @ 2015-05-20 16:55 U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G5vdCBoYXZlIGRyaXZlcnMgaW4gdGhlIGtlcm5lbCwgDQo+IHRodXMgdGhlIHVzZXJz
IGFyZSBkZXBlbmRlbnQgb24gdGhhdCBraW5kIG9mIGV4dGVybmFsIHJlcG87IGhvd2V2ZXIsIEkg
ZG8gbm90IA0KPiBoYXZlIGFueSBkZXNpcmUgdG8gZmluZCBvdXQgd2hhdCBtYWNybyBuZWVkcyB0
byBiZSB0ZXN0ZWQgc28gdGhhdCB0aGVzZSBkcml2ZXJzIA0KPiB3aWxsIGJ1aWxkIG9uIGRpc3Ry
b3MgdGhhdCBJIGRvIG5vdCB1c2UuDQo+IA0KPiBJIGd1ZXNzIEkgc2hvdWxkIHJlcG9ydCBhIGJ1
ZyB0byB3aGF0ZXZlciBkaXN0byBicmVha3MgbXkgZHJpdmVyIGFuZCByZXF1ZXN0IA0KPiB0aGF0
IHRoZXkgZml4IGl0LiBJIGFscmVhZHkga25vdyBob3cgbXVjaCB0aGF0IHdpbGwgaGVscCA6KQ0K
PiANCg0KSGVoIC0geWVhaC4gSSBjYW4gdGVsbCBJIHRyeSB0byBiZSAqdmVyeSogcmVzcG9uc2l2
ZSB3aGVuIHBlb3BsZSBhZGQNCmJ1Z3Mgb24gYnVnemlsbGEua2VybmVsLm9yZyBhYm91dCBpd2x3
aWZpLiBTb21lIHBlb3BsZSBhcmUgc3VycHJpc2VkIHRvDQpzZWUgdGhhdCB0aGUgaXNzdWUgaXMg
YWN0dWFsbHkgaGFuZGxlZCBhbmQgdGhhdCBzb21lb25lIHRha2VzIGNhcmUgb2YNCml0LiBUaGF0
IHRlYWNoZXMgbWUgd2hhdCBoYXBwZW5zIHRvIHRoZSBvdGhlciBpc3N1ZXMuLi4gOikNCg0KPiBM
YXJyeQ0KPiANCj4gDQoNCg==

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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20 16:53             ` Larry Finger
  2015-05-20 16:55               ` Grumbach, Emmanuel
@ 2015-05-20 16:59               ` Johannes Berg
  1 sibling, 0 replies; 16+ messages in thread
From: Johannes Berg @ 2015-05-20 16:59 UTC (permalink / raw)
  To: Larry Finger; +Cc: Grumbach, Emmanuel, backports

On Wed, 2015-05-20 at 11:53 -0500, Larry Finger wrote:
> On 05/20/2015 11:42 AM, Grumbach, Emmanuel wrote:
> >
> > Good question... I don't know. OTOH, distros don't really support
> > backport. You can't really blame them if they break backport, why should
> > they care?
> > I agree. It is annoying. We can try to convince them, but I don't think
> > that saying "you are all wrong" is the right path. Maybe we should try
> > to have them more involved in backport to fix it themselves?
> > And explain to them how important it is to be able to run backport on
> > top of all their shipped kernels?
> 
> Supporting backport would be a first step, but that won't help all of the rtl8* 
> repos that I have at GitHub. Most of those do not have drivers in the kernel, 
> thus the users are dependent on that kind of external repo; however, I do not 
> have any desire to find out what macro needs to be tested so that these drivers 
> will build on distros that I do not use.

Maybe you could just use backports for those drivers?

johannes


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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-19 13:42 [PATCH] backport: allow compilation with Ubuntu's 3.13 Emmanuel Grumbach
  2015-05-20  8:27 ` Johannes Berg
@ 2015-05-25 21:52 ` Hauke Mehrtens
  2015-06-08  8:17   ` Luca Coelho
  1 sibling, 1 reply; 16+ messages in thread
From: Hauke Mehrtens @ 2015-05-25 21:52 UTC (permalink / raw)
  To: Emmanuel Grumbach, backports

On 05/19/2015 03:42 PM, Emmanuel Grumbach wrote:
> Canonical backported:
> 
> Author: Or Gerlitz <ogerlitz@mellanox.com>
> Date:   Mon Jan 20 13:59:19 2014 +0200
> 
>     net: Add GRO support for UDP encapsulating protocols
> 
> This is commit 2da204a8f67fbe25816cbce8cc8551f03d5b951a in their
> tree.
> Cope with that.
> 
> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
> ---
> Touch compiled only. And I don't really know how the UTS thing goes :)
> ---
>  backport/backport-include/linux/netdevice.h | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/backport/backport-include/linux/netdevice.h b/backport/backport-include/linux/netdevice.h
> index bb3fefb..61ac95c 100644
> --- a/backport/backport-include/linux/netdevice.h
> +++ b/backport/backport-include/linux/netdevice.h
> @@ -81,6 +81,7 @@ static inline void dev_consume_skb_any(struct sk_buff *skb)
>  	dev_kfree_skb_any(skb);
>  }
>  
> +#if (LINUX_VERSION_CODE == KERNEL_VERSION(3,13,11) && UTS_UBUNTU_RELEASE_ABI < 24)
>  struct pcpu_sw_netstats {
>  	u64     rx_packets;
>  	u64     rx_bytes;
> @@ -88,6 +89,7 @@ struct pcpu_sw_netstats {
>  	u64     tx_bytes;
>  	struct u64_stats_sync   syncp;
>  };
> +#endif
>  
>  #define netdev_tstats(dev)	((struct pcpu_sw_netstats *)dev->ml_priv)
>  #define netdev_assign_tstats(dev, e)	dev->ml_priv = (e);
> 


Thank you for the patch, it was applied and pushed.

I changed it into this:
+#if (LINUX_VERSION_CODE != KERNEL_VERSION(3,13,11) ||
UTS_UBUNTU_RELEASE_ABI < 24)
...
#endif

Hauke

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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-25 21:52 ` Hauke Mehrtens
@ 2015-06-08  8:17   ` Luca Coelho
  2015-06-08  8:25     ` Coelho, Luciano
  0 siblings, 1 reply; 16+ messages in thread
From: Luca Coelho @ 2015-06-08  8:17 UTC (permalink / raw)
  To: Hauke Mehrtens; +Cc: Emmanuel Grumbach, backports

On Mon, 2015-05-25 at 23:52 +0200, Hauke Mehrtens wrote:
> On 05/19/2015 03:42 PM, Emmanuel Grumbach wrote:
> > Canonical backported:
> > 
> > Author: Or Gerlitz <ogerlitz@mellanox.com>
> > Date:   Mon Jan 20 13:59:19 2014 +0200
> > 
> >     net: Add GRO support for UDP encapsulating protocols
> > 
> > This is commit 2da204a8f67fbe25816cbce8cc8551f03d5b951a in their
> > tree.
> > Cope with that.
> > 
> > Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
> > ---
> > Touch compiled only. And I don't really know how the UTS thing goes :)
> > ---
> >  backport/backport-include/linux/netdevice.h | 2 ++
> >  1 file changed, 2 insertions(+)
> > 
> > diff --git a/backport/backport-include/linux/netdevice.h b/backport/backport-include/linux/netdevice.h
> > index bb3fefb..61ac95c 100644
> > --- a/backport/backport-include/linux/netdevice.h
> > +++ b/backport/backport-include/linux/netdevice.h
> > @@ -81,6 +81,7 @@ static inline void dev_consume_skb_any(struct sk_buff *skb)
> >  	dev_kfree_skb_any(skb);
> >  }
> >  
> > +#if (LINUX_VERSION_CODE == KERNEL_VERSION(3,13,11) && UTS_UBUNTU_RELEASE_ABI < 24)
> >  struct pcpu_sw_netstats {
> >  	u64     rx_packets;
> >  	u64     rx_bytes;
> > @@ -88,6 +89,7 @@ struct pcpu_sw_netstats {
> >  	u64     tx_bytes;
> >  	struct u64_stats_sync   syncp;
> >  };
> > +#endif
> >  
> >  #define netdev_tstats(dev)	((struct pcpu_sw_netstats *)dev->ml_priv)
> >  #define netdev_assign_tstats(dev, e)	dev->ml_priv = (e);
> > 
> 
> 
> Thank you for the patch, it was applied and pushed.
> 
> I changed it into this:
> +#if (LINUX_VERSION_CODE != KERNEL_VERSION(3,13,11) ||
> UTS_UBUNTU_RELEASE_ABI < 24)
> ...
> #endif

Isn't this still wrong? What if the kernel is >= 3,13,11? In that case,
the struct will be already defined... and if it's an upstream kernel
(i.e. UTS_UBUNTU_RELEASE_ABI is not defined) we will still try to
redefine this struct, no?

--
Luca.


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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-06-08  8:17   ` Luca Coelho
@ 2015-06-08  8:25     ` Coelho, Luciano
  0 siblings, 0 replies; 16+ messages in thread
From: Coelho, Luciano @ 2015-06-08  8:25 UTC (permalink / raw)
  To: hauke; +Cc: backports, Grumbach, Emmanuel

T24gTW9uLCAyMDE1LTA2LTA4IGF0IDExOjE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mV0ZGV2X2Fzc2lnbl90c3RhdHMoZGV2LCBlKQlkZXYtPm1sX3ByaXYgPSAoZSk7DQo+ID4g
PiANCj4gPiANCj4gPiANCj4gPiBUaGFuayB5b3UgZm9yIHRoZSBwYXRjaCwgaXQgd2FzIGFwcGxp
ZWQgYW5kIHB1c2hlZC4NCj4gPiANCj4gPiBJIGNoYW5nZWQgaXQgaW50byB0aGlzOg0KPiA+ICsj
aWYgKExJTlVYX1ZFUlNJT05fQ09ERSAhPSBLRVJORUxfVkVSU0lPTigzLDEzLDExKSB8fA0KPiA+
IFVUU19VQlVOVFVfUkVMRUFTRV9BQkkgPCAyNCkNCj4gPiAuLi4NCj4gPiAjZW5kaWYNCj4gDQo+
IElzbid0IHRoaXMgc3RpbGwgd3Jvbmc/IFdoYXQgaWYgdGhlIGtlcm5lbCBpcyA+PSAzLDEzLDEx
PyBJbiB0aGF0IGNhc2UsDQo+IHRoZSBzdHJ1Y3Qgd2lsbCBiZSBhbHJlYWR5IGRlZmluZWQuLi4g
YW5kIGlmIGl0J3MgYW4gdXBzdHJlYW0ga2VybmVsDQo+IChpLmUuIFVUU19VQlVOVFVfUkVMRUFT
RV9BQkkgaXMgbm90IGRlZmluZWQpIHdlIHdpbGwgc3RpbGwgdHJ5IHRvDQo+IHJlZGVmaW5lIHRo
aXMgc3RydWN0LCBubz8NCg0KSHVoLCBuZXZlciBtaW5kLCB0aGVyZSdzIHRoZSBMSU5VWF9WRVJT
SU9OX0NPREUgPCBLRVJORUxfVkVSU0lPTigzLDE0LDApDQpzdXJyb3VuZGluZyBpdC4uLiBNaXNz
ZWQgaXQuDQoNCi0tDQpMdWNhLg0K

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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-05-20 15:30         ` Larry Finger
  2015-05-20 16:42           ` Grumbach, Emmanuel
@ 2015-06-08 18:58           ` Luis R. Rodriguez
  2015-06-08 19:00             ` Luis R. Rodriguez
  1 sibling, 1 reply; 16+ messages in thread
From: Luis R. Rodriguez @ 2015-06-08 18:58 UTC (permalink / raw)
  To: Larry Finger; +Cc: Grumbach, Emmanuel, johannes, backports

On Wed, May 20, 2015 at 8:30 AM, Larry Finger <Larry.Finger@lwfinger.net> wrote:
> I am really pissed off about Ubuntu's backporting API changes so that
> testing LINUX_VERSION_CODE is no longer sufficient. In fact when someone
> complains the one of the out-of-kernel drivers that I maintain does not
> build with kernel X.Y, I check that version out in mainline, build the
> driver to make sure the problem is not mine, and then tell them to complain
> to their vendor. I no longer fix those problems. I think RHEL is also doing
> the same kind of thing - at least I did get one complaint about a build
> problem that seemed to be due to an API backport. Where do we stop?

Distros have been doing backporting for years, and their solutions
differ a bit, the Linux backports projects provides an outlet to
generalize a bit of this work through a systematic approach that aims
towards automation as much as possible. Some distributions have
already found value to this and embrace backports somehow, some others
are considering how to integrate it. For those distributions that have
already embraced backports and that also provide their own ABI they
resort to ABI solutions as described in this thread and patch. As an
example Red Hat already has integrated into backports support to
address ABI differences and they do that themselves, we welcome this.
Other distros should follow suit if they need this as well, and
obviously their solution should not interfere with the general
kernels.

On the other hand based on experience with these issues we have also
embraced proactive practices over time to try to avoid conflicts with
such kernel ABIs, one example was to embrace the #idef foo strategy
which checks to see if a kernel has defined a "foo" API already
instead of #if code with LINUX_VERSION_CODE stuff in which we know an
upstream kernel defined it, as is typically done. This is a strategy
*new* developers can embrace to help with this problem but it means
new code should use these #define strategies somehow when introducing
APIs.

For a while now I have been suggesting that over time we will likely
run into concrete items for automation for backporting or just general
backporting which could implicate how we should do development
upstream. This is an example of one of those best practices that could
be widely embraced to help make backporter's life easier. If we want
to take this a step further, which I want to, we'd add a grammatical
strategy to help with automation but I don't think we're there yet to
formalize that precisely just yet.

 Luis

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

* Re: [PATCH] backport: allow compilation with Ubuntu's 3.13
  2015-06-08 18:58           ` Luis R. Rodriguez
@ 2015-06-08 19:00             ` Luis R. Rodriguez
  0 siblings, 0 replies; 16+ messages in thread
From: Luis R. Rodriguez @ 2015-06-08 19:00 UTC (permalink / raw)
  To: Larry Finger; +Cc: Grumbach, Emmanuel, johannes, backports

On Mon, Jun 8, 2015 at 11:58 AM, Luis R. Rodriguez <mcgrof@frijolero.org> wrote:
> This is a strategy
> *new* developers

Sorry I meant that developers can use for *new* upstream code.

 Luis

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

end of thread, other threads:[~2015-06-08 19:01 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-19 13:42 [PATCH] backport: allow compilation with Ubuntu's 3.13 Emmanuel Grumbach
2015-05-20  8:27 ` Johannes Berg
2015-05-20  8:31   ` Grumbach, Emmanuel
2015-05-20  8:34     ` Johannes Berg
2015-05-20  8:39       ` Grumbach, Emmanuel
2015-05-20 15:30         ` Larry Finger
2015-05-20 16:42           ` Grumbach, Emmanuel
2015-05-20 16:53             ` Larry Finger
2015-05-20 16:55               ` Grumbach, Emmanuel
2015-05-20 16:59               ` Johannes Berg
2015-06-08 18:58           ` Luis R. Rodriguez
2015-06-08 19:00             ` Luis R. Rodriguez
2015-05-20  8:36     ` Luca Coelho
2015-05-25 21:52 ` Hauke Mehrtens
2015-06-08  8:17   ` Luca Coelho
2015-06-08  8:25     ` Coelho, Luciano

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.