On Sat, Aug 31, 2019 at 10:32:41AM +0200, Christoph Hellwig wrote:
> On Mon, Aug 26, 2019 at 08:28:19PM +0100, Al Viro wrote:
> > For configfs bin_attr it won't work, simply because it wants the entire
> > thing to be present - callback parses the data.  For SCSI tape...  Maybe,
> > but you'll need to take care of the overlaps with ->write().  Right now
> > it can't happen (the last reference, about to be dropped right after
> > st_flush() returns); if we do that on each ->flush(), we will have to
> > cope with that fun and we'll need to keep an error (if any) for the
> > next call of st_flush() to pick and return.  I'm not saying it can't
> > be done, but that's really a question for SCSI folks.
> 
> So for the one real life example of the configfs attribute life
> actually is simpler.  acpi_table_aml_write verifies early on that
> the size matches what it expects.  So if we document that any future
> instance needs to be able to do that as well we should be able to
> get away with just writing it from ->flush.

I'm not sure I understand what you mean...  Do you want them to recognize
incomplete data and quietly bugger off when called on too early ->flush()?

Reply via email to