[PATCH][Jaunty SRU][Intrepid SRU] UBUNTU: Fix the error value in /proc/iomem passed by the kernel paramter "reserve=" on X86_64

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[PATCH][Jaunty SRU][Intrepid SRU] UBUNTU: Fix the error value in /proc/iomem passed by the kernel paramter "reserve=" on X86_64

Keng-Yu Lin
From: Keng-Yu Lin <[hidden email]>

SRU Justificatoin:

IMPACT: kernel parameter "reserve=" is not handled well on AMD64 and the value in /proc/iomem is not padded by 0xf in the front. The bug LP#187671 depends on this bug.

FIX: A patch from Zhang Rui fixed. The patch is also summitted to the mainline. The status on mainline bugzilla is "RESOLVED CODE_FIX". It may be merged into the mainline some day.

TEST: I tested on Karmic, Jaunty and Intrepid. The value in /proc/iomem is correct after applying this patch. The original reporter also tested on 2.6.28-11 kernel and reported to work well.

OriginalAuthor: Zhang Rui ([hidden email])
OriginalLocation: http://bugzilla.kernel.org/show_bug.cgi?id=13253
BugLink: https://bugs.launchpad.net/bugs/370003
Bug: #370003

Request-pull
  git://kernel.ubuntu.com/lexical/lexical-karmic.gif lp370003
  git://kernel.ubuntu.com/lexical/lexical-jaunty.gif lp370003
  git://kernel.ubuntu.com/lexical/lexical-intrepid.gif lp370003

  They are basically the same; the line numbers differ.

Signed-off-by: Keng-Yu Lin <[hidden email]>
---
 kernel/resource.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/resource.c b/kernel/resource.c
index ac5f3a3..78b0872 100644
--- a/kernel/resource.c
+++ b/kernel/resource.c
@@ -787,7 +787,7 @@ static int __init reserve_setup(char *str)
  static struct resource reserve[MAXRESERVE];
 
  for (;;) {
- int io_start, io_num;
+ unsigned int io_start, io_num;
  int x = reserved;
 
  if (get_option (&str, &io_start) != 2)
--
1.6.0.4


--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH][Jaunty SRU][Intrepid SRU] UBUNTU: Fix the error value in /proc/iomem passed by the kernel paramter "reserve=" on X86_64

Keng-Yu Lin
Sorry I have a silly typo, please s/gif/git/

  git://kernel.ubuntu.com/lexical/lexical-karmic.git lp370003
  git://kernel.ubuntu.com/lexical/lexical-jaunty.git lp370003
  git://kernel.ubuntu.com/lexical/lexical-intrepid.git lp370003

2009/6/30  <[hidden email]>:

> From: Keng-Yu Lin <[hidden email]>
>
> SRU Justificatoin:
>
> IMPACT: kernel parameter "reserve=" is not handled well on AMD64 and the value in /proc/iomem is not padded by 0xf in the front. The bug LP#187671 depends on this bug.
>
> FIX: A patch from Zhang Rui fixed. The patch is also summitted to the mainline. The status on mainline bugzilla is "RESOLVED CODE_FIX". It may be merged into the mainline some day.
>
> TEST: I tested on Karmic, Jaunty and Intrepid. The value in /proc/iomem is correct after applying this patch. The original reporter also tested on 2.6.28-11 kernel and reported to work well.
>
> OriginalAuthor: Zhang Rui ([hidden email])
> OriginalLocation: http://bugzilla.kernel.org/show_bug.cgi?id=13253
> BugLink: https://bugs.launchpad.net/bugs/370003
> Bug: #370003
>
> Request-pull
>  git://kernel.ubuntu.com/lexical/lexical-karmic.gif lp370003
>  git://kernel.ubuntu.com/lexical/lexical-jaunty.gif lp370003
>  git://kernel.ubuntu.com/lexical/lexical-intrepid.gif lp370003
>
>  They are basically the same; the line numbers differ.
>
> Signed-off-by: Keng-Yu Lin <[hidden email]>
> ---
>  kernel/resource.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/kernel/resource.c b/kernel/resource.c
> index ac5f3a3..78b0872 100644
> --- a/kernel/resource.c
> +++ b/kernel/resource.c
> @@ -787,7 +787,7 @@ static int __init reserve_setup(char *str)
>        static struct resource reserve[MAXRESERVE];
>
>        for (;;) {
> -               int io_start, io_num;
> +               unsigned int io_start, io_num;
>                int x = reserved;
>
>                if (get_option (&str, &io_start) != 2)
> --
> 1.6.0.4
>
>
> --
> kernel-team mailing list
> [hidden email]
> https://lists.ubuntu.com/mailman/listinfo/kernel-team
>

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH][Jaunty SRU][Intrepid SRU] UBUNTU: Fix the error value in /proc/iomem passed by the kernel paramter "reserve=" on X86_64

Stefan Bader-2
In reply to this post by Keng-Yu Lin
ACK. Though the problem itself is not serious, the referenced bug causes a lot
of problems on certain laptops. The change itself make sense as addresses never
should get negative and a range the same. (Though it works that way I am
slightly wondering whether io_start would not better be an unsigned long...)

Anyhow, we need to get yet another ACK for SRU.

Stefan

[hidden email] wrote:

> From: Keng-Yu Lin <[hidden email]>
>
> SRU Justificatoin:
>
> IMPACT: kernel parameter "reserve=" is not handled well on AMD64 and the value in /proc/iomem is not padded by 0xf in the front. The bug LP#187671 depends on this bug.
>
> FIX: A patch from Zhang Rui fixed. The patch is also summitted to the mainline. The status on mainline bugzilla is "RESOLVED CODE_FIX". It may be merged into the mainline some day.
>
> TEST: I tested on Karmic, Jaunty and Intrepid. The value in /proc/iomem is correct after applying this patch. The original reporter also tested on 2.6.28-11 kernel and reported to work well.
>
> OriginalAuthor: Zhang Rui ([hidden email])
> OriginalLocation: http://bugzilla.kernel.org/show_bug.cgi?id=13253
> BugLink: https://bugs.launchpad.net/bugs/370003
> Bug: #370003
>
> Request-pull
>   git://kernel.ubuntu.com/lexical/lexical-karmic.gif lp370003
>   git://kernel.ubuntu.com/lexical/lexical-jaunty.gif lp370003
>   git://kernel.ubuntu.com/lexical/lexical-intrepid.gif lp370003
>
>   They are basically the same; the line numbers differ.
>
> Signed-off-by: Keng-Yu Lin <[hidden email]>
> ---
>  kernel/resource.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/kernel/resource.c b/kernel/resource.c
> index ac5f3a3..78b0872 100644
> --- a/kernel/resource.c
> +++ b/kernel/resource.c
> @@ -787,7 +787,7 @@ static int __init reserve_setup(char *str)
>   static struct resource reserve[MAXRESERVE];
>  
>   for (;;) {
> - int io_start, io_num;
> + unsigned int io_start, io_num;
>   int x = reserved;
>  
>   if (get_option (&str, &io_start) != 2)


--

When all other means of communication fail, try words!



--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH][Jaunty SRU][Intrepid SRU] UBUNTU: Fix the error value in /proc/iomem passed by the kernel paramter "reserve=" on X86_64

Amit Kucheria-6
In reply to this post by Keng-Yu Lin
On 09 Jun 30, Keng-Yü Lin wrote:

> Sorry I have a silly typo, please s/gif/git/
>
>   git://kernel.ubuntu.com/lexical/lexical-karmic.git lp370003
>   git://kernel.ubuntu.com/lexical/lexical-jaunty.git lp370003
>   git://kernel.ubuntu.com/lexical/lexical-intrepid.git lp370003
>
> 2009/6/30  <[hidden email]>:
> > From: Keng-Yu Lin <[hidden email]>
> >
> > SRU Justificatoin:
> >
> > IMPACT: kernel parameter "reserve=" is not handled well on AMD64 and the value in /proc/iomem is not padded by 0xf in the front. The bug LP#187671 depends on this bug.
> >
> > FIX: A patch from Zhang Rui fixed. The patch is also summitted to the mainline. The status on mainline bugzilla is "RESOLVED CODE_FIX". It may be merged into the mainline some day.
> >
> > TEST: I tested on Karmic, Jaunty and Intrepid. The value in /proc/iomem is correct after applying this patch. The original reporter also tested on 2.6.28-11 kernel and reported to work well.
> >
> > OriginalAuthor: Zhang Rui ([hidden email])
> > OriginalLocation: http://bugzilla.kernel.org/show_bug.cgi?id=13253
> > BugLink: https://bugs.launchpad.net/bugs/370003
> > Bug: #370003
> >
> > Request-pull
> >  git://kernel.ubuntu.com/lexical/lexical-karmic.gif lp370003
> >  git://kernel.ubuntu.com/lexical/lexical-jaunty.gif lp370003
> >  git://kernel.ubuntu.com/lexical/lexical-intrepid.gif lp370003
> >
> >  They are basically the same; the line numbers differ.
> >
> > Signed-off-by: Keng-Yu Lin <[hidden email]>
> > ---
> >  kernel/resource.c |    2 +-
> >  1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > diff --git a/kernel/resource.c b/kernel/resource.c
> > index ac5f3a3..78b0872 100644
> > --- a/kernel/resource.c
> > +++ b/kernel/resource.c
> > @@ -787,7 +787,7 @@ static int __init reserve_setup(char *str)
> >        static struct resource reserve[MAXRESERVE];
> >
> >        for (;;) {
> > -               int io_start, io_num;
> > +               unsigned int io_start, io_num;
> >                int x = reserved;
> >
> >                if (get_option (&str, &io_start) != 2)
> > --
> > 1.6.0.4
> >

ACK. Looks fairly straighforward.

--
----------------------------------------------------------------------
Amit Kucheria, Kernel Engineer || [hidden email]
----------------------------------------------------------------------

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH][Jaunty SRU][Intrepid SRU] UBUNTU: Fix the error value in /proc/iomem passed by the kernel paramter "reserve=" on X86_64

Stefan Bader-2
In reply to this post by Keng-Yu Lin
The patch has hit upstream in the meantime. So I changed the headers and
description while applying it. This will get automatically into Karmic with the
-rc2 sync.

I will not add this to Intrepid as I try to keep the updates there to the
minimum by being substantially stricter there. If someone has a strong opinion
on this, please say so.

Applied and pushed for Jaunty.

Stefan

--
kernel-team mailing list
[hidden email]
https://lists.ubuntu.com/mailman/listinfo/kernel-team