Re: [PATCH] cifs: handle -EINTR in cifs_setattr

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

 



On Wed, Oct 7, 2020 at 8:45 PM Aurélien Aptel <aaptel@xxxxxxxx> wrote:
>
> ronnie sahlberg <ronniesahlberg@xxxxxxxxx> writes:
> > glibc have handling for EINTR in most places, but not in for example utimensat()
> > because this function is not supposed to be able to return this error.
> > Similarly we have functions like chmod and chown that also come into cifs.ko
> > via the same entrypoint: cifs_setattr()
> > I think all of these "update inode data" are never supposed to be
> > interruptible since
> > they were classically just updating the in-memory inode and the thread
> > would never hit d-state.
>
> I see, thanks for the explanation.
>
> > Anyway, for these functions EINTR is not a valid return code so I
> > think we should take care to not
> > return it. Even if we change glibc adn the very very thin wrapper for
> > this functions there are applications
> > that might call the systemcall directly or via a different c-library.
>
> Should we use is_retryable_error() to check for the errcode?


That is probably a good idea.
I will resend the patch with that suggestion.

Thanks!
>
> Cheers,
> --
> Aurélien Aptel / SUSE Labs Samba Team
> GPG: 1839 CB5F 9F5B FB9B AA97  8C99 03C8 A49B 521B D5D3
> SUSE Software Solutions Germany GmbH, Maxfeldstr. 5, 90409 Nürnberg, DE
> GF: Felix Imendörffer, Mary Higgins, Sri Rasiah HRB 247165 (AG München)




[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux