qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Andre Przywara <andre.przywara@amd.com>
To: qemu-devel@nongnu.org
Cc: blauwirbel@gmail.com
Subject: [Qemu-devel] [PATCH] Remove redundant #ifdef _BSD
Date: Wed, 10 Dec 2008 20:21:04 +0100	[thread overview]
Message-ID: <494016A0.1090907@amd.com> (raw)

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

Hi,

since _BSD if already handled in osdep.c:qemu_memalign(), we don't need 
to check it in the calling function again. getpagesize() is available in 
BSD.

Regards,
Andre.

Signed-off-by: Andre Przywara <andre.przywara@amd.com>

-- 
Andre Przywara
AMD-Operating System Research Center (OSRC), Dresden, Germany
Tel: +49 351 277-84917
----to satisfy European Law for business letters:
AMD Saxony Limited Liability Company & Co. KG,
Wilschdorfer Landstr. 101, 01109 Dresden, Germany
Register Court Dresden: HRA 4896, General Partner authorized
to represent: AMD Saxony LLC (Wilmington, Delaware, US)
General Manager of AMD Saxony LLC: Dr. Hans-R. Deppe, Thomas McCoy

[-- Attachment #2: rem_bsd_ifdef.patch --]
[-- Type: text/x-patch, Size: 376 bytes --]

diff -r fb954e9c4a86 osdep.c
--- a/osdep.c	Wed Dec 10 19:23:18 2008 +0100
+++ b/osdep.c	Wed Dec 10 20:19:06 2008 +0100
@@ -200,11 +200,7 @@ void *qemu_vmalloc(size_t size)
     if (kqemu_allowed)
         return kqemu_vmalloc(size);
 #endif
-#ifdef _BSD
-    return valloc(size);
-#else
     return qemu_memalign(getpagesize(), size);
-#endif
 }
 
 void qemu_vfree(void *ptr)

             reply	other threads:[~2008-12-10 19:20 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-10 19:21 Andre Przywara [this message]
2008-12-11 19:41 ` [Qemu-devel] Re: [PATCH] Remove redundant #ifdef _BSD Blue Swirl

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=494016A0.1090907@amd.com \
    --to=andre.przywara@amd.com \
    --cc=blauwirbel@gmail.com \
    --cc=qemu-devel@nongnu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).