lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <53AB6FFF.4000506@linux.intel.com>
Date:	Thu, 26 Jun 2014 08:57:35 +0800
From:	"Zhang, Yanmin" <yanmin_zhang@...ux.intel.com>
To:	Liu hua <sdu.liu@...wei.com>, "Luck, Tony" <tony.luck@...el.com>,
	"anton@...msg.org" <anton@...msg.org>,
	"ccross@...roid.com" <ccross@...roid.com>,
	"keescook@...omium.org" <keescook@...omium.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
CC:	Wang Nan <wangnan0@...wei.com>,
	"peifeiyue@...wei.com" <peifeiyue@...wei.com>,
	Liu ShuoX <shuox.liu@...el.com>, Rocher@...r.kernel.org,
	Jeremy <jeremy.rocher@...el.com>
Subject: Re: Should Pstore(ramoops) records customized information?


On 2014/6/25 21:08, Liu hua wrote:
> 于 2014/6/25 8:41, Zhang, Yanmin 写道:
>> On 2014/6/20 18:47, Liu hua wrote:
>>> On 2014/6/20 7:42, Luck, Tony wrote:
>>>
>>>>> BTW, I note that "extern struct pstore_info *psinfo" locates in
>>>>> fs/pstore/internal.h. So users out of directory "fs/pstore/" can not use pstore to
>>>>> record messages. We do not want other kernel users to use pstore, right?  And can we
>>>>> break this?
>>>> Yes we can make some interface visible to the rest of the kernel ... probably
>>>> not the raw "*psinfo" though. Perhaps the pstore_alloc_ring_buffer() and
>>>> pstore_write_ring_buffer() functions should be the ones exported to the
>>>> rest of the kernel.
>>>>
>>>>> ditoo.. Since other backends like efi and erst may can not privide such ring buffer.
>>>>> So pstore_alloc_ring_buffer should be a funciton pointer of pstore_info struct.
>>>> Yes - that allows less capable backend like ERST and efivars to not provide the
>>>> service.  Since it becomes internal, you can drop the "pstore_" prefix.  E.g.
>>>> something like:
>>>>
>>>> int pstore_alloc_ring_buffer(char *name, int size)
>>>> {
>>>>      return psinfo->alloc_ring_buffer(name, size);
>>>> }
>>>> EXPORT_SYMBOL_GPL(pstore_alloc_ring_buffer);
>>>>
>>>> ... and you have to find/make some global header for the "extern" declaration.
>>> I will make these RFC patch series according to our discussion. Thanks you very to
>>> valuable advice.
>> Sorry for seeing your email late.We already worked out some patches to restructure
>> pstore. Would you like to try patchset http://article.gmane.org/gmane.linux.kernel/1697680/?
>>
>> We have more patches available to add some flags to disable/enable specific zones.
> That's great! I have tried your patches. BTW, Your patches do not work on ARM platform,
> before I changed linker scripts;

Initially, we just implemented it on x86. It's easy to extend it to ARM. Mostly change the arm
vmlinux.lds.S to add the sections. Pls. also change setup_arch to allocate memory blocks for
pstore.
In the patchset, there is an example patch, including reserve memory and zone examples.
Pls. reference it.

>   And can we use this method in modules(I failed to do that)?

It's a good question. There are many approaches to support modules.
1) Define the zone in built-in files and export it.Then, you can use it in module.
2) Define the zone and new tracer functions in built-in files and export
the tracer functions.

>
> After a quick glance and try, I think my idea is a little different from yours. I will reply you
> later.

Pls. Share your opinions. We are improving pstore to make it easier to be used.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ