Re: [PATCH v2 4/5] ACPI / extlog: Switch to use new generic UUID API
From: Andy Shevchenko
Date: Mon Jun 05 2017 - 12:23:44 EST
On Mon, 2017-06-05 at 18:06 +0200, Christoph Hellwig wrote:
> > @@ -165,11 +165,11 @@ static int extlog_print(struct notifier_block
> > *nb, unsigned long val,
> > Â err_seq++;
> > Â gdata = (struct acpi_hest_generic_data *)(tmp + 1);
> > Â if (gdata->validation_bits & CPER_SEC_VALID_FRU_ID)
> > - fru_id = (uuid_le *)gdata->fru_id;
> > + fru_id = (guid_t *)gdata->fru_id;
> > Â if (gdata->validation_bits & CPER_SEC_VALID_FRU_TEXT)
> > Â fru_text = gdata->fru_text;
> > - sec_type = (uuid_le *)gdata->section_type;
> > - if (!uuid_le_cmp(*sec_type, CPER_SEC_PLATFORM_MEM)) {
> > + sec_type = (guid_t *)gdata->section_type;
>
> From a quick look over the tree it seems like both fru_id and
> section_type should be declared as guid_t in
> struct acpi_hest_generic_data.
They are arrays of 16 u8:s.
And since it's defined in ACPI table definition I'm not sure we can
change it.
>
> > + if (!guid_equal(sec_type, &CPER_SEC_PLATFORM_MEM)) {
>
> The "!" seems incorrect here.
Right.
--
Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
Intel Finland Oy