Vasant Hegde <hegdevas...@linux.vnet.ibm.com> writes:
>> index 0000000..32fe7f5
>> --- /dev/null
>> +++ b/Documentation/ABI/stable/sysfs-firmware-opal-dump
>> @@ -0,0 +1,41 @@
>> +What:               /sys/firmware/opal/dump
>> +Date:               Feb 2014
>> +Contact:    Stewart Smith <stew...@linux.vnet.ibm.com>
>> +Description:
>> +            This directory exposes interfaces for interacting with
>> +            the FSP and platform dumps through OPAL firmware interface.
>> +
>> +            This is only for the powerpc/powernv platform.
>> +
>> +            initiate_dump:  When '1' is written to it,
>> +                            we will initiate a dump.
>
> initiate FSP dump

ack. I can send subsequent patch that fixes up these bits.

>> --- /dev/null
>> +++ b/arch/powerpc/platforms/powernv/opal-dump.c
>> @@ -0,0 +1,525 @@
>> +/*
>> + * PowerNV OPAL Dump Interface
>> + *
>> + * Copyright 2013,2014 IBM Corp.
>> + *
>> + * This program is free software; you can redistribute it and/or
>> + * modify it under the terms of the GNU General Public License
>> + * as published by the Free Software Foundation; either version
>> + * 2 of the License, or (at your option) any later version.
>> + */
>> +
>> +#include <linux/kobject.h>
>> +#include <linux/mm.h>
>> +#include <linux/slab.h>
>> +#include <linux/vmalloc.h>
>> +#include <linux/pagemap.h>
>> +#include <linux/delay.h>
>> +
>> +#include <asm/opal.h>
>> +
>> +#define DUMP_TYPE_FSP       0x01
>
> Better define other dump type (sysdump etc) here and use it below ?

Likely yes, Is there a definitive list somewhere?

>> +static ssize_t init_dump_store(struct dump_obj *dump_obj,
>> +                           struct dump_attribute *attr,
>> +                           const char *buf,
>> +                           size_t count)
>> +{
>> +    dump_fips_init(DUMP_TYPE_FSP);
>> +    pr_info("%s: Initiated FSP dump\n", __func__);
>
> This might mislead if OPAL fails to initiate FSP dump.. Better move this to 
> dump_fips_init () ?

good point. I don't think we actually process the response of FSP dump
init, which IIRC may actually be able to tell us if it failed to
initiate a dump.

_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

Reply via email to