* [Qemu-devel] [PATCH v2] smbios: changed for "smbios_build_type_17_table()" to take 'uint64_t'
@ 2014-11-04 7:12 SeokYeon Hwang
2014-11-04 8:42 ` Paolo Bonzini
0 siblings, 1 reply; 3+ messages in thread
From: SeokYeon Hwang @ 2014-11-04 7:12 UTC (permalink / raw)
To: qemu-devel; +Cc: paolo.bonzini, armbru, alex.williamson, SeokYeon Hwang
"smbios_build_type_17_table()" should take 'uint64_t' instead of 'ram_addr_t' because it should be able to handle (16ll * GiB).
Otherwise, clang (>= 3.4) produces compilation warning in "smbios_get_tables()".
Signed-off-by: SeokYeon Hwang <syeon.hwang@samsung.com>
---
hw/i386/smbios.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/i386/smbios.c b/hw/i386/smbios.c
index 8a7ad48..4ad42ae 100644
--- a/hw/i386/smbios.c
+++ b/hw/i386/smbios.c
@@ -669,7 +669,7 @@ static void smbios_build_type_16_table(unsigned dimm_cnt)
#define MAX_T17_STD_SZ 0x7FFF /* (32G - 1M), in Megabytes */
#define MAX_T17_EXT_SZ 0x80000000 /* 2P, in Megabytes */
-static void smbios_build_type_17_table(unsigned instance, ram_addr_t size)
+static void smbios_build_type_17_table(unsigned instance, uint64_t size)
{
char loc_str[128];
ram_addr_t size_mb;
--
2.1.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH v2] smbios: changed for "smbios_build_type_17_table()" to take 'uint64_t'
2014-11-04 7:12 [Qemu-devel] [PATCH v2] smbios: changed for "smbios_build_type_17_table()" to take 'uint64_t' SeokYeon Hwang
@ 2014-11-04 8:42 ` Paolo Bonzini
2014-11-05 6:19 ` SeokYeon Hwang
0 siblings, 1 reply; 3+ messages in thread
From: Paolo Bonzini @ 2014-11-04 8:42 UTC (permalink / raw)
To: SeokYeon Hwang, qemu-devel; +Cc: paolo.bonzini, armbru, alex.williamson
On 04/11/2014 08:12, SeokYeon Hwang wrote:
> "smbios_build_type_17_table()" should take 'uint64_t' instead of 'ram_addr_t' because it should be able to handle (16ll * GiB).
> Otherwise, clang (>= 3.4) produces compilation warning in "smbios_get_tables()".
>
> Signed-off-by: SeokYeon Hwang <syeon.hwang@samsung.com>
> ---
> hw/i386/smbios.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/i386/smbios.c b/hw/i386/smbios.c
> index 8a7ad48..4ad42ae 100644
> --- a/hw/i386/smbios.c
> +++ b/hw/i386/smbios.c
> @@ -669,7 +669,7 @@ static void smbios_build_type_16_table(unsigned dimm_cnt)
> #define MAX_T17_STD_SZ 0x7FFF /* (32G - 1M), in Megabytes */
> #define MAX_T17_EXT_SZ 0x80000000 /* 2P, in Megabytes */
>
> -static void smbios_build_type_17_table(unsigned instance, ram_addr_t size)
> +static void smbios_build_type_17_table(unsigned instance, uint64_t size)
> {
> char loc_str[128];
> ram_addr_t size_mb;
>
Can you make a patch that replaces _all_ occurrences in hw/i386/smbios.c
instead?
Thanks,
Paolo
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Qemu-devel] [PATCH v2] smbios: changed for "smbios_build_type_17_table()" to take 'uint64_t'
2014-11-04 8:42 ` Paolo Bonzini
@ 2014-11-05 6:19 ` SeokYeon Hwang
0 siblings, 0 replies; 3+ messages in thread
From: SeokYeon Hwang @ 2014-11-05 6:19 UTC (permalink / raw)
To: 'Paolo Bonzini', qemu-devel
Cc: paolo.bonzini, armbru, alex.williamson
> -----Original Message-----
> From: Paolo Bonzini [mailto:paolo.bonzini@gmail.com] On Behalf Of Paolo
> Bonzini
> Sent: Tuesday, November 04, 2014 5:42 PM
> To: SeokYeon Hwang; qemu-devel@nongnu.org
> Cc: paolo.bonzini@gmail.com; armbru@redhat.com; alex.williamson@hp.com
> Subject: Re: [PATCH v2] smbios: changed for "smbios_build_type_17_table()"
> to take 'uint64_t'
>
>
>
> On 04/11/2014 08:12, SeokYeon Hwang wrote:
> > "smbios_build_type_17_table()" should take 'uint64_t' instead of
> 'ram_addr_t' because it should be able to handle (16ll * GiB).
> > Otherwise, clang (>= 3.4) produces compilation warning in
> "smbios_get_tables()".
> >
> > Signed-off-by: SeokYeon Hwang <syeon.hwang@samsung.com>
> > ---
> > hw/i386/smbios.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/hw/i386/smbios.c b/hw/i386/smbios.c index
> > 8a7ad48..4ad42ae 100644
> > --- a/hw/i386/smbios.c
> > +++ b/hw/i386/smbios.c
> > @@ -669,7 +669,7 @@ static void smbios_build_type_16_table(unsigned
> > dimm_cnt) #define MAX_T17_STD_SZ 0x7FFF /* (32G - 1M), in Megabytes
> > */ #define MAX_T17_EXT_SZ 0x80000000 /* 2P, in Megabytes */
> >
> > -static void smbios_build_type_17_table(unsigned instance, ram_addr_t
> > size)
> > +static void smbios_build_type_17_table(unsigned instance, uint64_t
> > +size)
> > {
> > char loc_str[128];
> > ram_addr_t size_mb;
> >
>
> Can you make a patch that replaces _all_ occurrences in hw/i386/smbios.c
> instead?
>
> Thanks,
>
> Paolo
I just posted patch v3 that is applied your suggestion.
Thank you for your advice.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-11-05 6:20 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-11-04 7:12 [Qemu-devel] [PATCH v2] smbios: changed for "smbios_build_type_17_table()" to take 'uint64_t' SeokYeon Hwang
2014-11-04 8:42 ` Paolo Bonzini
2014-11-05 6:19 ` SeokYeon Hwang
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).