Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1573822 > unrolled thread
| Started by | Stafford Horne <shorne@gmail.com> |
|---|---|
| First post | 2017-02-05 08:10 +0100 |
| Last post | 2017-02-07 03:50 +0100 |
| Articles | 6 — 3 participants |
Back to article view | Back to linux.kernel
[PATCH 0/2] Remove unneeded stddef.h includes Stafford Horne <shorne@gmail.com> - 2017-02-05 08:10 +0100
[PATCH 2/2] staging: vchip_shim: Remove unneeded stddef.h include Stafford Horne <shorne@gmail.com> - 2017-02-05 08:10 +0100
[PATCH 1/2] libceph: Remove unneeded stddef.h include Stafford Horne <shorne@gmail.com> - 2017-02-05 08:10 +0100
Re: [PATCH 1/2] libceph: Remove unneeded stddef.h include Ilya Dryomov <idryomov@gmail.com> - 2017-02-06 11:20 +0100
RE: [PATCH 1/2] libceph: Remove unneeded stddef.h include David Laight <David.Laight@ACULAB.COM> - 2017-02-06 17:20 +0100
Re: [PATCH 1/2] libceph: Remove unneeded stddef.h include Stafford Horne <shorne@gmail.com> - 2017-02-07 03:50 +0100
| From | Stafford Horne <shorne@gmail.com> |
|---|---|
| Date | 2017-02-05 08:10 +0100 |
| Subject | [PATCH 0/2] Remove unneeded stddef.h includes |
| Message-ID | <t7p7r-46L-1@gated-at.bofh.it> |
Hi All, These were causing openrisc build to fail when building with allyesconfig using a musl toolchain. Removing them doesnt seem to cause any issues. The line removed was: #include <stddef.h> Perhaps what was wanted was 'linux/stddef.h' but there did seem to be any special uses so I just removed it. Also, sending these patches should help the kbuild robots verify that. If I can get acks I will push it in with my openrisc branch. But if this should got through the net and staging paths I am happy with that. -Stafford Stafford Horne (2): libceph: Remove unneeded stddef.h include staging: vchip_shim: Remove unneeded stddef.h include drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c | 2 -- net/ceph/snapshot.c | 2 -- 2 files changed, 4 deletions(-) -- 2.9.3
[toc] | [next] | [standalone]
| From | Stafford Horne <shorne@gmail.com> |
|---|---|
| Date | 2017-02-05 08:10 +0100 |
| Subject | [PATCH 2/2] staging: vchip_shim: Remove unneeded stddef.h include |
| Message-ID | <t7p7r-46L-7@gated-at.bofh.it> |
| In reply to | #1573822 |
Building on openrisc musl toolchain this causes the allyesconfig build
to fail.
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c:42:20:
fatal error: stddef.h: No such file or directory
Removing this causes no issues with the build.
Signed-off-by: Stafford Horne <shorne@gmail.com>
---
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c
index d977139..70c530c 100644
--- a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c
+++ b/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_shim.c
@@ -39,8 +39,6 @@
#include "vchiq_util.h"
-#include <stddef.h>
-
#define vchiq_status_to_vchi(status) ((int32_t)status)
typedef struct {
--
2.9.3
[toc] | [prev] | [next] | [standalone]
| From | Stafford Horne <shorne@gmail.com> |
|---|---|
| Date | 2017-02-05 08:10 +0100 |
| Subject | [PATCH 1/2] libceph: Remove unneeded stddef.h include |
| Message-ID | <t7p7r-46L-5@gated-at.bofh.it> |
| In reply to | #1573822 |
This was causing a build failure for openrisc when using musl and gcc 5.4.0 since the file is not available in the toolchain. It doesnt seem this is needed and removing it does not cause any build warnings for me. Signed-off-by: Stafford Horne <shorne@gmail.com> --- net/ceph/snapshot.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/net/ceph/snapshot.c b/net/ceph/snapshot.c index 154683f..705414e 100644 --- a/net/ceph/snapshot.c +++ b/net/ceph/snapshot.c @@ -18,8 +18,6 @@ * 02110-1301, USA. */ -#include <stddef.h> - #include <linux/types.h> #include <linux/export.h> #include <linux/ceph/libceph.h> -- 2.9.3
[toc] | [prev] | [next] | [standalone]
| From | Ilya Dryomov <idryomov@gmail.com> |
|---|---|
| Date | 2017-02-06 11:20 +0100 |
| Subject | Re: [PATCH 1/2] libceph: Remove unneeded stddef.h include |
| Message-ID | <t7OyT-3E0-35@gated-at.bofh.it> |
| In reply to | #1573824 |
On Sun, Feb 5, 2017 at 8:07 AM, Stafford Horne <shorne@gmail.com> wrote:
> This was causing a build failure for openrisc when using musl and
> gcc 5.4.0 since the file is not available in the toolchain.
>
> It doesnt seem this is needed and removing it does not cause any build
> warnings for me.
>
> Signed-off-by: Stafford Horne <shorne@gmail.com>
> ---
> net/ceph/snapshot.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/net/ceph/snapshot.c b/net/ceph/snapshot.c
> index 154683f..705414e 100644
> --- a/net/ceph/snapshot.c
> +++ b/net/ceph/snapshot.c
> @@ -18,8 +18,6 @@
> * 02110-1301, USA.
> */
>
> -#include <stddef.h>
> -
> #include <linux/types.h>
> #include <linux/export.h>
> #include <linux/ceph/libceph.h>
Applied.
Thanks,
Ilya
[toc] | [prev] | [next] | [standalone]
| From | David Laight <David.Laight@ACULAB.COM> |
|---|---|
| Date | 2017-02-06 17:20 +0100 |
| Subject | RE: [PATCH 1/2] libceph: Remove unneeded stddef.h include |
| Message-ID | <t7Ubg-7e3-13@gated-at.bofh.it> |
| In reply to | #1573824 |
From: Stafford Horne > Sent: 05 February 2017 07:08 > This was causing a build failure for openrisc when using musl and > gcc 5.4.0 since the file is not available in the toolchain. > > It doesnt seem this is needed and removing it does not cause any build > warnings for me. Hmmm... stddef.h is part of the SuS v2. Required to get definitions for NULL, offsetof(), ptrdiff_t and size_t. So any system that is pretending to by unix-like ought to have one. David
[toc] | [prev] | [next] | [standalone]
| From | Stafford Horne <shorne@gmail.com> |
|---|---|
| Date | 2017-02-07 03:50 +0100 |
| Subject | Re: [PATCH 1/2] libceph: Remove unneeded stddef.h include |
| Message-ID | <t840V-54B-5@gated-at.bofh.it> |
| In reply to | #1574941 |
On Mon, Feb 06, 2017 at 04:16:55PM +0000, David Laight wrote:
> From: Stafford Horne
> > Sent: 05 February 2017 07:08
> > This was causing a build failure for openrisc when using musl and
> > gcc 5.4.0 since the file is not available in the toolchain.
> >
> > It doesnt seem this is needed and removing it does not cause any build
> > warnings for me.
>
> Hmmm... stddef.h is part of the SuS v2.
> Required to get definitions for NULL, offsetof(), ptrdiff_t and size_t.
>
> So any system that is pretending to by unix-like ought to have one.
Hello,
I agree, and also I can see that musl and gcc both do provide it. I am
not sure why its not getting included for kernel builds, I didnt look
into it much because on the other hand...
Linux also provides it in 'linux/stddef.h'. In this case vchiq_shim.c
includes "vchiq_util.h".
which includes "linux/string.h"
which includes "linux/stddef.h"
So the requirement seems satisfied.
I am fine to send a patch to change the include to <linux/stddef.h> as I
mentioned in the cover letter. But I dont think its really needed.
-Stafford
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web