All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tim Deegan <tim@xen.org>
To: Costin Lupu <costin.lupu@cs.pub.ro>
Cc: xen-devel@lists.xenproject.org, Ian Jackson <iwj@xenproject.org>,
	Wei Liu <wl@xen.org>
Subject: Re: [PATCH 1/5] tools/debugger: Fix PAGE_SIZE redefinition error
Date: Thu, 29 Apr 2021 20:58:31 +0100	[thread overview]
Message-ID: <YIsP5z1ejJbUhmPc@deinos.phlegethon.org> (raw)
In-Reply-To: <0cd234096c9bfa8d29eac9906553af79d378733e.1619524463.git.costin.lupu@cs.pub.ro>

Hi,

At 15:05 +0300 on 27 Apr (1619535916), Costin Lupu wrote:
> If PAGE_SIZE is already defined in the system (e.g. in
> /usr/include/limits.h header) then gcc will trigger a redefinition error
> because of -Werror. This commit also protects PAGE_SHIFT definitions for
> keeping consistency.

Thanks for looking into this!  I think properly speaking we should fix
this by defining KDD_PAGE_SHIFT and KDD_PAGE_SIZE in kdd.h and using
those everywhere we currently use PAGE_SIZE/PAGE_SHIFT. in kdd.c and
kdd-xen.c.  If for some reason we ever ended up with a system-defined
PAGE_SIZE that wasn't 4096u then we would not want to use it here
because it would break our guest operations.

Cheers,

Tim


  reply	other threads:[~2021-04-29 19:59 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-27 12:05 [PATCH 0/5] Fix redefinition errors for toolstack libs Costin Lupu
2021-04-27 12:05 ` [PATCH 1/5] tools/debugger: Fix PAGE_SIZE redefinition error Costin Lupu
2021-04-29 19:58   ` Tim Deegan [this message]
2021-04-30 11:36     ` Costin Lupu
2021-04-30 18:45       ` Tim Deegan
2021-04-30 19:33         ` Costin Lupu
2021-04-27 12:05 ` [PATCH 2/5] tools/libfsimage: Fix PATH_MAX " Costin Lupu
2021-04-28  9:04   ` Julien Grall
2021-04-28 18:35     ` Costin Lupu
2021-04-29 11:39       ` Julien Grall
2021-04-27 12:05 ` [PATCH 3/5] tools/libs/foreignmemory: Fix PAGE_SIZE " Costin Lupu
2021-04-28  9:03   ` Julien Grall
2021-04-28 18:27     ` Costin Lupu
2021-04-29 11:29       ` Julien Grall
2021-04-27 12:05 ` [PATCH 4/5] tools/libs/gnttab: " Costin Lupu
2021-04-27 12:05 ` [PATCH 5/5] tools/ocaml: Fix redefinition errors Costin Lupu
2021-04-28 12:34 ` [PATCH 0/5] Fix redefinition errors for toolstack libs Christian Lindig
2021-04-28 18:37   ` Costin Lupu

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=YIsP5z1ejJbUhmPc@deinos.phlegethon.org \
    --to=tim@xen.org \
    --cc=costin.lupu@cs.pub.ro \
    --cc=iwj@xenproject.org \
    --cc=wl@xen.org \
    --cc=xen-devel@lists.xenproject.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.