Re: [PATCH 2/5] pstore: Introduce write_buf backend callback

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, May 29, 2012 at 06:00:16PM +0000, Luck, Tony wrote:
> > Hrm, I thought the point of having pstore.buf pre-mapped was to allow
> > Oopses to be able to write directly to it without needing to hit any
> > additional kernel code. Maybe I'm misunderstanding this change,
> > though. I'd like to see Tony's opinion on it.
> 
> Yes - the ERST backend needs to have a bunch of header ugliness (with
> special UUIDs) at the front of the buffer that is stored to non-volatile
> storage. So it allocates its own buffer with all that junk, and then
> passes the address of the plain data portion of the buffer on to the
> pstore layer.
> 
> As we add more backends, it might be that this is only applicable to
> ERST, and so it might make sense to have it copy the data from some
> other buffer into its specially crafted one.  But we should not lose
> the "no allocations" property ... everything needed should be pre-allocated
> so we don't have to try to allocate any memory during a panic.

Yep, and everything is still pre-allocated.

The only change is that we can pass different buffers, and in tracing
case it is allocated on the stack (we can't use pstore.buf for tracing
as it would require grabbing pstore_lock, which we can't do -- the
locking operations are traced too, so it would recurse).

Thanks,

-- 
Anton Vorontsov
Email: cbouatmailru@xxxxxxxxx
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel


[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux