All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrei Borzenkov <arvidjaar@gmail.com>
To: Michael Zimmermann <sigmaepsilon92@gmail.com>
Cc: The development of GNU GRUB <grub-devel@gnu.org>
Subject: Re: Division Bugs
Date: Mon, 6 Apr 2015 19:34:23 +0300	[thread overview]
Message-ID: <20150406193423.6efdca20@opensuse.site> (raw)
In-Reply-To: <CAN9vWDK97uG8aZXBuuUxP=FrR2_y7=MiypJ4H5gJdmV_LmHxxg@mail.gmail.com>

В Sat, 4 Apr 2015 22:49:28 +0200
Michael Zimmermann <sigmaepsilon92@gmail.com> пишет:

> I think I found a bug but I'm not sure.
> 
> http://git.savannah.gnu.org/gitweb/?p=grub.git;a=blob;f=grub-core/lib/division.c;h=920a79f18b7a7180bc5bcf18987c043b1df56687;hb=refs/heads/master#l53
> at line 53 u write a value to ro:
> *ro = r;
> 
> now take a look at the callers:
> http://git.savannah.gnu.org/gitweb/?p=grub.git;a=blob;f=grub-core/kern/compiler-rt.c;h=d4cc15513aabea3061bd2dddc896b105bb180a5b;hb=refs/heads/master
> 
> some look like this which should be ok:
> grub_divmod64s (a, b, &ret);
> 
> but there are others like this:
> grub_divmod64s (a, b, 0);
> 
> I got a "data abort, translation fault on write" exception after
> compiling a lib which uses that division function.
> 

Fixed. Unfortunately there does not appear any easy way to
regression test it. Dereferencing 0x0 pointer does not trigger an error,
unless you setup address mapping appropriately.

Thank you for report!


      reply	other threads:[~2015-04-06 16:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-04 20:49 Division Bugs Michael Zimmermann
2015-04-06 16:34 ` Andrei Borzenkov [this message]

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=20150406193423.6efdca20@opensuse.site \
    --to=arvidjaar@gmail.com \
    --cc=grub-devel@gnu.org \
    --cc=sigmaepsilon92@gmail.com \
    /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.