Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Felix Zielcke
bered a compact algorithm for detecting loops of such kind I > >> will implement it and submit a patch and we'll see how really > compact > >> it is > > Here it is. Strange that I haven't remembered this algorithm before. > > Can someone test this patc

Re: Rotated menu on EFI?

2009-07-25 Thread Michal Suchanek
2009/7/25 Vladimir 'phcoder' Serbinenko : >> >> >> No, I mean that the arrow keys work normally but the menu is drawn >> rotated to match the screen orientation. > This would require > (a) video support for EFI. This is simple to implement once > framebuffer split is in > (b) rotation support in gf

Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
On Sun, Jul 26, 2009 at 12:58 AM, Vladimir 'phcoder' Serbinenko wrote: > On Sun, Jul 26, 2009 at 12:35 AM, Vladimir 'phcoder' > Serbinenko wrote: >>> Links backwards between extended partition entries are more likely to be >>> due to data corruption than due to buggy partitoning tools.  OK, if you

Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
On Sun, Jul 26, 2009 at 12:35 AM, Vladimir 'phcoder' Serbinenko wrote: >> Links backwards between extended partition entries are more likely to be >> due to data corruption than due to buggy partitoning tools.  OK, if you >> want, let's support up to 10 backward links.  That's more than enough. > I

Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
> Links backwards between extended partition entries are more likely to be > due to data corruption than due to buggy partitoning tools.  OK, if you > want, let's support up to 10 backward links.  That's more than enough. I remembered a compact algorithm for detecting loops of such kind I will impl

[PATCH] Centralizing understanding of far pointers

2009-07-25 Thread Javier Martín
This patch modifies the machine-specific memory.h (currently, just the i386-specific file), adding a new type grub_machine_farptr and two functions to convert between such far pointers and normal C pointers. The code performing the mapping between realmode and pmode addresses is simple, and thus i

Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Pavel Roskin
On Sat, 2009-07-25 at 18:56 +0200, Vladimir 'phcoder' Serbinenko wrote: > On Sat, Jul 25, 2009 at 6:36 PM, Robert Millan wrote: > > On Fri, Jul 24, 2009 at 09:24:31PM +0200, Felix Zielcke wrote: > >> + loop = 0; > >> + while (loop < 10) > >> [...] > >> + if (loop == 10) > >> +return

Re: [PATCH 2/2] SDL support

2009-07-25 Thread Pavel Roskin
On Sat, 2009-07-25 at 18:26 +0200, Robert Millan wrote: > On Thu, Jul 23, 2009 at 08:19:24PM -0400, Pavel Roskin wrote: > > > > Also, when compiling on PowerPC, configure reports that SDL is enabled, > > but it is not. The same applies to USB support. > > Shouldn't it be enabled in all architect

Re: [PATCH] Check for the appropriate condition in types.h

2009-07-25 Thread Javier Martín
El jue, 23-07-2009 a las 16:57 -0400, Pavel Roskin escribió: > On Thu, 2009-07-23 at 22:30 +0200, Vladimir 'phcoder' Serbinenko wrote: > > >> > [GRUB_CPU_SIZEOF_VOID_P == 8]: Changed to ... > > >> > [GRUB_CPU_SIZEOF_LONG == 8]: ... this. > > >> Ok, let's adopt this form instead. The proposed Change

Re: [PATCH] Bug fix for LVM

2009-07-25 Thread Felix Zielcke
Am Montag, den 20.07.2009, 03:34 +0800 schrieb Bean: > On Mon, Jul 20, 2009 at 3:11 AM, Patrik Horník wrote: > > Bean, should Grub2 with this patch work if the boot partition is LVM > > volume and LVM is placed on top of RAID 5 arrays? > > Hi, > > Yeah, it should work, please try it out. > I ju

Re: [PATCH] xfs bug fix

2009-07-25 Thread Bean
Hi, This is an update version of the patch. -- Bean diff --git a/fs/xfs.c b/fs/xfs.c index ddaba57..d1bcd15 100644 --- a/fs/xfs.c +++ b/fs/xfs.c @@ -46,7 +46,8 @@ struct grub_xfs_sblock grub_uint8_t unused4[20]; grub_uint8_t label[12]; grub_uint8_t log2_bsize; - grub_uint8_t unused5[2]

Re: Rotated menu on EFI?

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
> > > No, I mean that the arrow keys work normally but the menu is drawn > rotated to match the screen orientation. This would require (a) video support for EFI. This is simple to implement once framebuffer split is in (b) rotation support in gfxterm. Patches are welcome > > Thanks > > Michal > > >

Re: Rotated menu on EFI?

2009-07-25 Thread Michal Suchanek
2009/7/25 Robert Millan : > On Fri, Jul 24, 2009 at 09:33:45PM +0200, Michal Suchanek wrote: >> Hello >> >> Is there some chance that the grub menu could be drawn rotated on >> graphical devices like the efi graphics interface? > > I'm not sure what you mean by rotation.  You mean that arrow keys >

Re: [PATCH] New object format

2009-07-25 Thread Bean
Hi, Update: New tool grub-mkrawimage, used to generate img file from object files directly, no need for ld and objcopy anymore. It inject the grub_bss_start and grub_bss_end symbol, so no need to check for them in configure.ac. Remove the memcpy alias in kern/misc.c, instead, it map memcpy to gr

search --help says --file is default but it fails when not specified

2009-07-25 Thread Felix Zielcke
Currently help output of search says that --file option is the default but a `search /file' fails with `unspecified search type'. So which behaviour do we want? -- Felix Zielcke Proud Debian Maintainer ___ Grub-devel mailing list Grub-devel@gnu.org h

Re: [PATCH] DAC palette width retrieval

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
>> *_mask normally shouldn't be used in index color by internal grub >> functions anyway. And if payload needs a special convention for >> passing color info for indexed modes it should be handled by loader > > Ok.  But if we decide that *_mask should go away, this is quite independant > from this

Re: [Fwd: Bug#503344: Grub-pc fails on IBM x3250 configured with RAID-1]

2009-07-25 Thread Felix Zielcke
Am Samstag, den 25.07.2009, 18:45 +0200 schrieb Robert Millan: > On Sat, Jul 25, 2009 at 01:35:02AM +0200, Felix Zielcke wrote: > > Is this an acceptable fix? > > Though I have the feeling this isn't a proper one. > > > > Weitergeleitete Nachricht > > > Von: Bob Gilligan > > > R

Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
On Sat, Jul 25, 2009 at 6:36 PM, Robert Millan wrote: > On Fri, Jul 24, 2009 at 09:24:31PM +0200, Felix Zielcke wrote: >> +  loop = 0; >> +  while (loop < 10) >> [...] >> +  if (loop == 10) >> +    return grub_error (GRUB_ERR_BAD_PART_TABLE, "Corrupted partition table >> found."); > > What

Re: [Fwd: Bug#538381: grub-pc: keystroke freezes grub2 at kernel selection menu]

2009-07-25 Thread Felix Zielcke
Am Samstag, den 25.07.2009, 18:47 +0200 schrieb Robert Millan: > On Sat, Jul 25, 2009 at 03:13:58PM +0200, Felix Zielcke wrote: > > Anyone has an idea why keyboard in grub2 freezes but in grub-legacy not? > > I'd suggest set debug=all and see the last thing GRUB did before freeze. > I don't thin

Re: [PATCH] DAC palette width retrieval

2009-07-25 Thread Robert Millan
On Sat, Jul 25, 2009 at 02:24:22PM +0200, Vladimir 'phcoder' Serbinenko wrote: > > Now I'm not completely sure where does this belong.  I think it's somewhat > > generic and we can reasonably expect other OSes to want this information > > too, but I'm not completely sure. > For me putting these val

Re: [Fwd: Bug#538381: grub-pc: keystroke freezes grub2 at kernel selection menu]

2009-07-25 Thread Robert Millan
On Sat, Jul 25, 2009 at 03:13:58PM +0200, Felix Zielcke wrote: > Anyone has an idea why keyboard in grub2 freezes but in grub-legacy not? I'd suggest set debug=all and see the last thing GRUB did before freeze. -- Robert Millan The DRM opt-in fallacy: "Your data belongs to us. We will decide

Re: [PATCH] Support FreeBSD in osdetect.lua

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
>> LUA will probably be important for graphics. > > It can be useful, yes, but not essential.  Native scripting should continue > to be supported, since the whole grub-mkconfig stack relies on it. Yes, but graphics itself isn't essential either. And I also agree that sh should be privelegied. But s

Re: [Fwd: Bug#503344: Grub-pc fails on IBM x3250 configured with RAID-1]

2009-07-25 Thread Robert Millan
On Sat, Jul 25, 2009 at 01:35:02AM +0200, Felix Zielcke wrote: > Is this an acceptable fix? > Though I have the feeling this isn't a proper one. > > Weitergeleitete Nachricht > > Von: Bob Gilligan > > Reply-to: Bob Gilligan , 503...@bugs.debian.org > > An: sub...@bugs.debian.org

Re: Rotated menu on EFI?

2009-07-25 Thread Robert Millan
On Fri, Jul 24, 2009 at 09:33:45PM +0200, Michal Suchanek wrote: > Hello > > Is there some chance that the grub menu could be drawn rotated on > graphical devices like the efi graphics interface? I'm not sure what you mean by rotation. You mean that arrow keys navigate back to the top when press

Re: [Fwd: Re: Bug#495949: grub-common: grub-probe segfaults]

2009-07-25 Thread Robert Millan
On Fri, Jul 24, 2009 at 11:17:08PM +0200, Vladimir 'phcoder' Serbinenko wrote: > On Fri, Jul 24, 2009 at 10:56 PM, Pavel Roskin wrote: > > On Fri, 2009-07-24 at 22:37 +0200, Vladimir 'phcoder' Serbinenko wrote: > > > >> Actualy I already fixed this in my patch for installing on > >> partitionless d

Re: [Fwd: Re: Bug#495949: grub-common: grub-probe segfaults]

2009-07-25 Thread Robert Millan
On Fri, Jul 24, 2009 at 04:33:44PM -0400, Pavel Roskin wrote: > + else > +{ > + grub_util_warn ("Embedding on partition type %s is unsupported", > + dest_partmap); >goto unable_to_embed; > } This extends blocklist support for label types other than MSDOS or

Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Robert Millan
On Fri, Jul 24, 2009 at 09:24:31PM +0200, Felix Zielcke wrote: > + loop = 0; > + while (loop < 10) > [...] > + if (loop == 10) > +return grub_error (GRUB_ERR_BAD_PART_TABLE, "Corrupted partition table > found."); What does this 10 represent? It looks like heuristic, but I'm mi

Re: [Fwd: Bug#532202: grub-pc: behaves strange in virtualbox with a disk > 2 TB]

2009-07-25 Thread Robert Millan
On Fri, Jul 24, 2009 at 01:57:45PM +0200, Samuel Thibault wrote: > Hello, > > This is most probably a bug of the BIOS. I had pushed to bochs' BIOS > a patch to implement LBA48 so as to overcome the LBA28 limitation > (2^28*512 = 128GB), but it still has a 2^32 sectors limitation as all > computat

Re: [PATCH 2/2] SDL support

2009-07-25 Thread Robert Millan
On Thu, Jul 23, 2009 at 08:19:24PM -0400, Pavel Roskin wrote: > > Also, when compiling on PowerPC, configure reports that SDL is enabled, > but it is not. The same applies to USB support. Shouldn't it be enabled in all architectures? Unfortunately, the grub-emu definition is arch-specific, but

Re: [PATCH] zero-fill entry before asking BIOS for memory map

2009-07-25 Thread Robert Millan
On Thu, Jul 23, 2009 at 05:31:57PM -0400, Pavel Roskin wrote: > On Thu, 2009-07-23 at 11:38 +0200, Vladimir 'phcoder' Serbinenko wrote: > > Hello. According to xen some BIOSes update only lower 32-bit in mmap > > entries. To workaround this and not get high values in memory map > > zero-fill before

Re: [BUGFIX] Don't use DT_DIR: It doesn't work on non-ext* filesystems

2009-07-25 Thread Robert Millan
On Fri, Jul 24, 2009 at 05:49:19PM -0400, Pavel Roskin wrote: > On Fri, 2009-07-24 at 23:02 +0200, Christian Franke wrote: > > > A correct performance-aware solution would look like: > > > > #ifdef DT_DIR > > if (de->d_type == DT_DIR) > > info.dir = 1; > > else if (de->type == DT_FILE) >

Re: [PATCH] Faster text rendering by optimizing font glyph lookup

2009-07-25 Thread Felix Zielcke
Am Samstag, den 25.07.2009, 18:04 +0200 schrieb Robert Millan: > On Fri, Jul 24, 2009 at 11:17:59PM +0200, Felix Zielcke wrote: > > > > So if there still won't come up objections against this, then I'll do > > the change, then at least an Ubuntu bug report can be closed. > > I think it's fine, bu

Re: [PATCH 2/2] Alias cls as clear

2009-07-25 Thread Robert Millan
On Thu, Jul 23, 2009 at 04:05:00PM -0700, Joe Auricchio wrote: > > On 23 Jul, 2009, at 15:42 , Pavel Roskin wrote: >> On Wed, 2009-07-22 at 22:08 -0700, Joe Auricchio wrote: >>> * commands/minicmd.c: Add clear as alias for cls. >>> >>> My background is in Unix, so 'clear' comes much more naturally

Re: [PATCH 2/2] Alias cls as clear

2009-07-25 Thread Robert Millan
On Thu, Jul 23, 2009 at 06:42:11PM -0400, Pavel Roskin wrote: > On Wed, 2009-07-22 at 22:08 -0700, Joe Auricchio wrote: > > * commands/minicmd.c: Add clear as alias for cls. > > > > My background is in Unix, so 'clear' comes much more naturally to my > > fingers than 'cls'. But it's bad to clutter

Re: grub-0.97/btrfs: the files fsys_btrfs.c, btrfs.h

2009-07-25 Thread Robert Millan
On Wed, Jul 22, 2009 at 08:40:47PM +0200, Edward Shishkin wrote: >>> Anyway, nice to see that you work on btrfs for grub. >>> But grub-legacy is totally dead now, it would be better if you would put >>> your efforts into grub2. >>> > > Mm.. I am not an individual contributor. > I work for RHEL

Re: [PATCH] Support FreeBSD in osdetect.lua

2009-07-25 Thread Robert Millan
On Wed, Jul 22, 2009 at 08:02:02PM +0200, Vladimir 'phcoder' Serbinenko wrote: > > I think we should contemplate to put LUA scripting in grub-extras too.  Like > > other components of grub-extras, we don't have copyright assignment for it, > > so it would fit well the purpose of grub-extras.  This

Re: [PATCH] Call a module's init function only after the module is successfully added

2009-07-25 Thread Robert Millan
On Wed, Jul 22, 2009 at 02:25:14PM -0400, Pavel Roskin wrote: > On Wed, 2009-07-22 at 19:36 +0200, Robert Millan wrote: > > On Tue, Jul 21, 2009 at 04:02:48PM -0400, Pavel Roskin wrote: > > > > > > By the way, kern/dl.c have some unused functions (grub_dl_unload_all). > > > > grub_machine_fini()

Re: [PATCH] Bug fix for LVM

2009-07-25 Thread Robert Millan
On Thu, Jul 23, 2009 at 02:58:50AM +0800, Bean wrote: > On Thu, Jul 23, 2009 at 1:33 AM, Robert Millan wrote: > > On Sun, Jul 19, 2009 at 05:41:04PM +0800, Bean wrote: > >> +      if (is_raid) > >> +     printf ("raid mdraid"); > >> + > >> +      if (is_lvm) > >> +     printf ((is_raid) ? " lvm" :

Re: [PATCH] Faster text rendering by optimizing font glyph lookup

2009-07-25 Thread Robert Millan
On Fri, Jul 24, 2009 at 11:17:59PM +0200, Felix Zielcke wrote: > > So if there still won't come up objections against this, then I'll do > the change, then at least an Ubuntu bug report can be closed. I think it's fine, but is this an upstream change or a debian change? IIRC the default font sel

Re: [RFC, PATCH] C99 format specifiers for fixed-length integer types

2009-07-25 Thread Javier Martín
El jue, 23-07-2009 a las 17:48 -0400, Pavel Roskin escribió: > On Thu, 2009-07-23 at 23:25 +0200, Javier Martín wrote: > > > With the reduced version of the patch I'm putting forward, such a > > (hypothetical, indeed) change will only impact types.h, while otherwise > > many source files will need

[Fwd: Bug#538381: grub-pc: keystroke freezes grub2 at kernel selection menu]

2009-07-25 Thread Felix Zielcke
Anyone has an idea why keyboard in grub2 freezes but in grub-legacy not? Weitergeleitete Nachricht > Von: Bruce LaZerte > Reply-to: b...@fwr.on.ca, 538...@bugs.debian.org > An: submit > Betreff: Bug#538381: grub-pc: keystroke freezes grub2 at kernel > selection menu > Datum: Sa

Re: [PATCH] DAC palette width retrieval

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
> Now I'm not completely sure where does this belong.  I think it's somewhat > generic and we can reasonably expect other OSes to want this information > too, but I'm not completely sure. For me putting these values to *_mask is ok but it may put some limits for future cards but as payloads have no

[PATCH] DAC palette width retrieval

2009-07-25 Thread Robert Millan
When using packed color modes, Linux expects we fill the color sizes with the value obtained from the DAC. If we give it zeroes (like we currently do) it displays a blank screen. This can be reproduced by attempting to boot Linux with a 8-bit color mode (e.g. set gfxpayload=800x600x8). Now I'm

Re: [PATCH] fix an infinite loop with a corrupted pc partition table

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
On Fri, Jul 24, 2009 at 11:03 PM, Pavel Roskin wrote: > On Fri, 2009-07-24 at 22:35 +0200, Vladimir 'phcoder' Serbinenko wrote: > This is still allowed: > > MBR  >  Ext >        Logical  <-/ AFAIK this isn't even possible since e->start is unsigned and references to logical par

Re: Fwd: [PATCH 1/2] Framebuffer split

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
On Fri, Jul 24, 2009 at 1:41 AM, Pavel Roskin wrote: > On Thu, 2009-07-23 at 11:52 +0200, Vladimir 'phcoder' Serbinenko wrote: >> Hello. Here is a framebuffer split which has already been discussed. >> This patch contains some code by Collin D Bennett in addition to my >> code. Sorry for compressio

Re: [Fwd: Bug#503344: Grub-pc fails on IBM x3250 configured with RAID-1]

2009-07-25 Thread Felix Zielcke
Am Samstag, den 25.07.2009, 10:37 +0200 schrieb Vladimir 'phcoder' Serbinenko: > On Sat, Jul 25, 2009 at 1:35 AM, Felix Zielcke wrote: > > Is this an acceptable fix? > > Though I have the feeling this isn't a proper one. > > > >> > >> The fix is to assign grub_errno before making the call to > >> g

Re: [Fwd: Bug#503344: Grub-pc fails on IBM x3250 configured with RAID-1]

2009-07-25 Thread Vladimir 'phcoder' Serbinenko
On Sat, Jul 25, 2009 at 1:35 AM, Felix Zielcke wrote: > Is this an acceptable fix? > Though I have the feeling this isn't a proper one. > >> >> The fix is to assign grub_errno before making the call to >> grub_file_get_device_name(): Just check whether returned device_name is 0 or not >> >> diff --