Re: [PATCH 1/3] nfs: Drop pointless check from nfs_commit_release_pages()

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

 



On Thu, 2024-06-13 at 10:28 +0200, Jan Kara wrote:
> nfss->writeback is updated only when we are ending page writeback and
> at
> that moment we also clear nfss->write_congested. So there's no point
> in
> rechecking congestion state in nfs_commit_release_pages(). Drop the
> pointless check.
> 
> Signed-off-by: Jan Kara <jack@xxxxxxx>
> ---
>  fs/nfs/write.c | 4 ----
>  1 file changed, 4 deletions(-)
> 
> diff --git a/fs/nfs/write.c b/fs/nfs/write.c
> index 5fc12a721ec3..c6255d7edd3c 100644
> --- a/fs/nfs/write.c
> +++ b/fs/nfs/write.c
> @@ -1837,7 +1837,6 @@ static void nfs_commit_release_pages(struct
> nfs_commit_data *data)
>  	struct nfs_page	*req;
>  	int status = data->task.tk_status;
>  	struct nfs_commit_info cinfo;
> -	struct nfs_server *nfss;
>  	struct folio *folio;
>  
>  	while (!list_empty(&data->pages)) {
> @@ -1880,9 +1879,6 @@ static void nfs_commit_release_pages(struct
> nfs_commit_data *data)
>  		/* Latency breaker */
>  		cond_resched();
>  	}
> -	nfss = NFS_SERVER(data->inode);
> -	if (atomic_long_read(&nfss->writeback) <
> NFS_CONGESTION_OFF_THRESH)
> -		nfss->write_congested = 0;
>  
>  	nfs_init_cinfo(&cinfo, data->inode, data->dreq);
>  	nfs_commit_end(cinfo.mds);

Reviewed-by: Jeff Layton <jlayton@xxxxxxxxxx>





[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux