linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] apm_event{,info}_t are userspace types.
@ 2007-11-30 20:02 Adam Jackson
  2007-12-12 10:47 ` Andrew Morton
  2007-12-18  4:33 ` Rusty Russell
  0 siblings, 2 replies; 5+ messages in thread
From: Adam Jackson @ 2007-11-30 20:02 UTC (permalink / raw)
  To: linux-kernel; +Cc: Adam Jackson

These types define the size of data read from /dev/apm_bios.  They
should not be hidden behind #ifdef __KERNEL__.
---
 include/linux/apm_bios.h |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/linux/apm_bios.h b/include/linux/apm_bios.h
index 9754baa..01a6244 100644
--- a/include/linux/apm_bios.h
+++ b/include/linux/apm_bios.h
@@ -18,6 +18,9 @@
 
 #include <linux/types.h>
 
+typedef unsigned short	apm_event_t;
+typedef unsigned short	apm_eventinfo_t;
+
 struct apm_bios_info {
 	__u16	version;
 	__u16	cseg;
@@ -32,9 +35,6 @@ struct apm_bios_info {
 
 #ifdef __KERNEL__
 
-typedef unsigned short	apm_event_t;
-typedef unsigned short	apm_eventinfo_t;
-
 #define APM_CS		(GDT_ENTRY_APMBIOS_BASE * 8)
 #define APM_CS_16	(APM_CS + 8)
 #define APM_DS		(APM_CS_16 + 8)
-- 
1.5.2.4


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

* Re: [PATCH] apm_event{,info}_t are userspace types.
  2007-11-30 20:02 [PATCH] apm_event{,info}_t are userspace types Adam Jackson
@ 2007-12-12 10:47 ` Andrew Morton
  2007-12-13 21:03   ` Eamon Walsh
  2007-12-19 19:00   ` Adam Jackson
  2007-12-18  4:33 ` Rusty Russell
  1 sibling, 2 replies; 5+ messages in thread
From: Andrew Morton @ 2007-12-12 10:47 UTC (permalink / raw)
  To: Adam Jackson; +Cc: linux-kernel

On Fri, 30 Nov 2007 15:02:43 -0500 Adam Jackson <ajax@redhat.com> wrote:

> These types define the size of data read from /dev/apm_bios.  They
> should not be hidden behind #ifdef __KERNEL__.

Missing info: what are the consequences of this fix?  What id broken when
it it not applied?


> ---
>  include/linux/apm_bios.h |    6 +++---
>  1 files changed, 3 insertions(+), 3 deletions(-)

Please include Signed-off-by:, as per Documentation/SubmittingPatches,
thanks.

> diff --git a/include/linux/apm_bios.h b/include/linux/apm_bios.h
> index 9754baa..01a6244 100644
> --- a/include/linux/apm_bios.h
> +++ b/include/linux/apm_bios.h
> @@ -18,6 +18,9 @@
>  
>  #include <linux/types.h>
>  
> +typedef unsigned short	apm_event_t;
> +typedef unsigned short	apm_eventinfo_t;
> +
>  struct apm_bios_info {
>  	__u16	version;
>  	__u16	cseg;
> @@ -32,9 +35,6 @@ struct apm_bios_info {
>  
>  #ifdef __KERNEL__
>  
> -typedef unsigned short	apm_event_t;
> -typedef unsigned short	apm_eventinfo_t;
> -
>  #define APM_CS		(GDT_ENTRY_APMBIOS_BASE * 8)
>  #define APM_CS_16	(APM_CS + 8)
>  #define APM_DS		(APM_CS_16 + 8)


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

* Re: [PATCH] apm_event{,info}_t are userspace types.
  2007-12-12 10:47 ` Andrew Morton
@ 2007-12-13 21:03   ` Eamon Walsh
  2007-12-19 19:00   ` Adam Jackson
  1 sibling, 0 replies; 5+ messages in thread
From: Eamon Walsh @ 2007-12-13 21:03 UTC (permalink / raw)
  To: Andrew Morton; +Cc: Adam Jackson, linux-kernel, rusty

Andrew Morton wrote:
> On Fri, 30 Nov 2007 15:02:43 -0500 Adam Jackson <ajax@redhat.com> wrote:
> 
>> These types define the size of data read from /dev/apm_bios.  They
>> should not be hidden behind #ifdef __KERNEL__.
> 
> Missing info: what are the consequences of this fix?  What id broken when
> it it not applied?

This is killing my xserver compile, apm_event_t is used in the xserver 
source.  The commit that introduced the problem is:

commit ee8e7cfe9d330d6f1ce0b9b1620d6df5d9cf6b70
Author: Rusty Russell <rusty@rustcorp.com.au>
Date:   Mon Oct 22 10:56:19 2007 +1000

     Make asm-x86/bootparam.h includable from userspace.

     To actually write a bootloader (or, say, the lguest launcher)
     currently requires duplication of these structures.  Making them
     includable from userspace is much nicer.

     We merge the common userspace-required definitions of e820_32/64.h
     into e820.h for export.

     Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>

> 
> 
>> ---
>>  include/linux/apm_bios.h |    6 +++---
>>  1 files changed, 3 insertions(+), 3 deletions(-)
> 
> Please include Signed-off-by:, as per Documentation/SubmittingPatches,
> thanks.
> 
>> diff --git a/include/linux/apm_bios.h b/include/linux/apm_bios.h
>> index 9754baa..01a6244 100644
>> --- a/include/linux/apm_bios.h
>> +++ b/include/linux/apm_bios.h
>> @@ -18,6 +18,9 @@
>>  
>>  #include <linux/types.h>
>>  
>> +typedef unsigned short	apm_event_t;
>> +typedef unsigned short	apm_eventinfo_t;
>> +
>>  struct apm_bios_info {
>>  	__u16	version;
>>  	__u16	cseg;
>> @@ -32,9 +35,6 @@ struct apm_bios_info {
>>  
>>  #ifdef __KERNEL__
>>  
>> -typedef unsigned short	apm_event_t;
>> -typedef unsigned short	apm_eventinfo_t;
>> -
>>  #define APM_CS		(GDT_ENTRY_APMBIOS_BASE * 8)
>>  #define APM_CS_16	(APM_CS + 8)
>>  #define APM_DS		(APM_CS_16 + 8)
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
> 


-- 
Eamon Walsh <ewalsh@tycho.nsa.gov>
National Security Agency

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

* Re: [PATCH] apm_event{,info}_t are userspace types.
  2007-11-30 20:02 [PATCH] apm_event{,info}_t are userspace types Adam Jackson
  2007-12-12 10:47 ` Andrew Morton
@ 2007-12-18  4:33 ` Rusty Russell
  1 sibling, 0 replies; 5+ messages in thread
From: Rusty Russell @ 2007-12-18  4:33 UTC (permalink / raw)
  To: Adam Jackson; +Cc: linux-kernel, Andrew Morton, Stephen Rothwell

On Saturday 01 December 2007 07:02:43 Adam Jackson wrote:
> These types define the size of data read from /dev/apm_bios.  They
> should not be hidden behind #ifdef __KERNEL__.

Acked-by: Rusty Russell <rusty@rustcorp.com.au>

My mistake, sorry.

Rusty.

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

* Re: [PATCH] apm_event{,info}_t are userspace types.
  2007-12-12 10:47 ` Andrew Morton
  2007-12-13 21:03   ` Eamon Walsh
@ 2007-12-19 19:00   ` Adam Jackson
  1 sibling, 0 replies; 5+ messages in thread
From: Adam Jackson @ 2007-12-19 19:00 UTC (permalink / raw)
  To: Andrew Morton; +Cc: linux-kernel

On Wed, 2007-12-12 at 02:47 -0800, Andrew Morton wrote:
> On Fri, 30 Nov 2007 15:02:43 -0500 Adam Jackson <ajax@redhat.com> wrote:
> > These types define the size of data read from /dev/apm_bios.  They
> > should not be hidden behind #ifdef __KERNEL__.
> 
> Missing info: what are the consequences of this fix?  What id broken when
> it it not applied?

The X server won't build.  Neither will apmd, but it's harder for me to
get worked up about that.

> > ---
> >  include/linux/apm_bios.h |    6 +++---
> >  1 files changed, 3 insertions(+), 3 deletions(-)
> 
> Please include Signed-off-by:, as per Documentation/SubmittingPatches,
> thanks.

Blah.  Right, will remember git-format-patch -s next time.  In any
event:

Signed-off-by: Adam Jackson <ajax@redhat.com>

- ajax


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

end of thread, other threads:[~2007-12-19 18:36 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-30 20:02 [PATCH] apm_event{,info}_t are userspace types Adam Jackson
2007-12-12 10:47 ` Andrew Morton
2007-12-13 21:03   ` Eamon Walsh
2007-12-19 19:00   ` Adam Jackson
2007-12-18  4:33 ` Rusty Russell

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