From: "Vladimir 'φ-coder/phcoder' Serbinenko" <phcoder@gmail.com>
To: The development of GNU GRUB <grub-devel@gnu.org>
Subject: Re: [PATCH] Improve FreeDOS direct loading support compatibility.
Date: Sat, 07 Jul 2012 14:23:01 +0200 [thread overview]
Message-ID: <4FF82A25.9070504@gmail.com> (raw)
In-Reply-To: <op.wgpbisbv6p67p9@isor>
[-- Attachment #1: Type: text/plain, Size: 1620 bytes --]
On 30.06.2012 07:43, C. Masloch wrote:
> #define GRUB_FREEDOS_SEGMENT 0x60
> +#define GRUB_FREEDOS_ADDR (GRUB_FREEDOS_SEGMENT<<4)
> #define GRUB_FREEDOS_STACK_SEGMENT 0x1fe0
> -#define GRUB_FREEDOS_STACK_POINTER 0x8000
> +#define GRUB_FREEDOS_STACK_BPB_POINTER 0x7c00
> +#define GRUB_FREEDOS_BPB_ADDR ((GRUB_FREEDOS_STACK_SEGMENT<<4) \
> + +GRUB_FREEDOS_STACK_BPB_POINTER)
> +
Please put spaces around operators.
> +
> + /* This is not strictly necessary for the current FreeDOS kernel
> + but improves potential compatibility with the current EDR-DOS
> + load protocol.
DR-DOS is less-known proprietary software which we usually don't support
as policy. While it's ok to set those registers, please avoid
referencing DR-DOS directly, even in comments.
> + /* This check could be considered optional, but it provides a more
> + specific error message than grub_relocator_alloc_chunk_addr would,
> + and additionally it insures that a little is set aside for the
> + initial stack as well.
> + Quirkily, because of its size constraints FreeDOS's original loader
> + doesn't perform such a check at all (and crashes instead). The file
> + size limit is documented though. */
> + if (kernelsyssize > GRUB_FREEDOS_MAX_SIZE)
> + {
> + (void)grub_error (GRUB_ERR_BAD_OS,
> + "file `%s' is too large for a valid"
> + " FreeDOS kernel.sys", argv[0]);
No need of void cast here.
--
Regards
Vladimir 'φ-coder/phcoder' Serbinenko
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 294 bytes --]
next prev parent reply other threads:[~2012-07-07 12:23 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-30 5:43 [PATCH] Improve FreeDOS direct loading support compatibility C. Masloch
2012-07-07 12:23 ` Vladimir 'φ-coder/phcoder' Serbinenko [this message]
2012-07-08 8:28 ` C. Masloch
2012-09-09 19:49 ` Vladimir 'φ-coder/phcoder' Serbinenko
2012-09-09 21:37 ` C. Masloch
2013-01-27 15:08 ` 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=4FF82A25.9070504@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.