Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1300288

Re: [PATCH 2/5] nbd: Remove signal usage

Path csiph.com!news.freedyn.net!newsfeed.datemas.de!weretis.net!feeder1.news.weretis.net!newsfeed.CARNet.hr!news.spin.it!bofh.it!news.nic.it!robomod
From Christoph Hellwig <hch@infradead.org>
Newsgroups linux.kernel
Subject Re: [PATCH 2/5] nbd: Remove signal usage
Date Sun, 03 Jan 2016 13:00:02 +0100
Message-ID <qMPui-4Z2-3@gated-at.bofh.it> (permalink)
References <qMrrX-6Qc-3@gated-at.bofh.it> <qMrrY-6Qc-19@gated-at.bofh.it>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Disposition inline
User-Agent Mutt/1.5.23 (2014-03-12)
X-Srs-Rewrite SMTP reverse-path rewritten from <hch@infradead.org> by bombadil.infradead.org See http://www.infradead.org/rpr.html
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 21
Organization linux.* mail to news gateway
X-Original-Cc Jens Axboe <axboe@kernel.dk>, linux-kernel@vger.kernel.org, nbd-general@lists.sourceforge.net, kernel@pengutronix.de, Oleg Nesterov <oleg@redhat.com>, Christoph Hellwig <hch@infradead.org>
X-Original-Date Sun, 3 Jan 2016 03:56:31 -0800
X-Original-Message-ID <20160103115630.GA9803@infradead.org>
X-Original-References <1451729825-11481-1-git-send-email-mpa@pengutronix.de> <1451729825-11481-3-git-send-email-mpa@pengutronix.de>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1300288

Show key headers only | View raw


Hi Markus,

this looks great!

Reviewed-by: Christoph Hellwig <hch@lst.de>

One thing I noticed, which might be a good cleanup in the future:

> -	spin_lock_irqsave(&nbd->tasks_lock, flags);
>  	nbd->task_recv = current;
> -	spin_unlock_irqrestore(&nbd->tasks_lock, flags);

It seems like task_{send,recv} are only used for the files showing
the pids.  Maybe you should just store the pids directly in the
nbd_device structure and also keep the sysfs file around for the
life time of that structure.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PULL] NBD changes Markus Pargmann <mpa@pengutronix.de> - 2016-01-02 11:20 +0100
  [PATCH 1/5] nbd: Fix debugfs error handling Markus Pargmann <mpa@pengutronix.de> - 2016-01-02 11:20 +0100
    Re: [PATCH 1/5] nbd: Fix debugfs error handling kbuild test robot <lkp@intel.com> - 2016-01-02 13:00 +0100
    [PATCH] nbd: fix ifnullfree.cocci warnings kbuild test robot <lkp@intel.com> - 2016-01-02 13:00 +0100
  [PATCH 2/5] nbd: Remove signal usage Markus Pargmann <mpa@pengutronix.de> - 2016-01-02 11:20 +0100
    Re: [PATCH 2/5] nbd: Remove signal usage Christoph Hellwig <hch@infradead.org> - 2016-01-03 13:00 +0100

csiph-web