All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Vladimir 'φ-coder/phcoder' Serbinenko" <phcoder@gmail.com>
To: grub-devel@gnu.org
Subject: Re: Release of 2.00~rc1
Date: Sat, 23 Jun 2012 23:57:10 +0200	[thread overview]
Message-ID: <4FE63BB6.9090003@gmail.com> (raw)
In-Reply-To: <1340487031.26777.20.camel@pracovna>

[-- Attachment #1: Type: text/plain, Size: 1571 bytes --]

On 23.06.2012 23:30, Aleš Nesrsta wrote:

> Hi,
> I tried compile source from link and I got this error:
> 

Your compiler is too warning-prone :(
Try this:
=== modified file 'grub-core/loader/i386/linux.c'
--- grub-core/loader/i386/linux.c	2012-06-20 21:39:33 +0000
+++ grub-core/loader/i386/linux.c	2012-06-23 21:46:30 +0000
@@ -1043,7 +1043,6 @@
   grub_addr_t addr_min, addr_max;
   grub_addr_t addr;
   grub_err_t err;
-  struct linux_kernel_header *lh;
   int i;
   int nfiles = 0;
   grub_uint8_t *ptr;
@@ -1076,12 +1075,10 @@
 
   initrd_pages = (page_align (size) >> 12);
 
-  lh = (struct linux_kernel_header *) &linux_params;
-
   /* Get the highest address available for the initrd.  */
-  if (grub_le_to_cpu16 (lh->version) >= 0x0203)
+  if (grub_le_to_cpu16 (linux_params.version) >= 0x0203)
     {
-      addr_max = grub_cpu_to_le32 (lh->initrd_addr_max);
+      addr_max = grub_cpu_to_le32 (linux_params.initrd_addr_max);
 
       /* XXX in reality, Linux specifies a bogus value, so
 	 it is necessary to make sure that ADDR_MAX does not exceed
@@ -1144,9 +1141,9 @@
   grub_dprintf ("linux", "Initrd, addr=0x%x, size=0x%x\n",
 		(unsigned) addr, (unsigned) size);
 
-  lh->ramdisk_image = initrd_mem_target;
-  lh->ramdisk_size = size;
-  lh->root_dev = 0x0100; /* XXX */
+  linux_params.ramdisk_image = initrd_mem_target;
+  linux_params.ramdisk_size = size;
+  linux_params.root_dev = 0x0100; /* XXX */
 
  fail:
   for (i = 0; i < nfiles; i++)

-- 
Regards
Vladimir 'φ-coder/phcoder' Serbinenko


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 294 bytes --]

  reply	other threads:[~2012-06-23 21:57 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-23 20:59 Release of 2.00~rc1 Vladimir 'φ-coder/phcoder' Serbinenko
2012-06-23 21:30 ` Aleš Nesrsta
2012-06-23 21:57   ` Vladimir 'φ-coder/phcoder' Serbinenko [this message]
2012-06-24  7:29 ` Robert Mabee
2012-06-24 18:30   ` Vladimir 'φ-coder/phcoder' Serbinenko
2012-06-25  9:12     ` REG_EXTENDED (was Re: Release of 2.00~rc1) Vladimir 'φ-coder/phcoder' Serbinenko
2012-06-25 18:23   ` Release of 2.00~rc1 Vladimir 'φ-coder/phcoder' Serbinenko
2012-06-26  2:16     ` Robert Mabee
2012-06-26  2:46       ` Vladimir 'φ-coder/phcoder' Serbinenko
2012-06-27  4:40         ` Robert Mabee
2012-06-25 14:29 ` David Cantrell
2012-06-26 18:27 ` Bruce Dubbs
2012-06-26 20:03   ` Vladimir 'φ-coder/phcoder' Serbinenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4FE63BB6.9090003@gmail.com \
    --to=phcoder@gmail.com \
    --cc=grub-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.