From: hch@lst.de (Christoph Hellwig)
Subject: [PATCH 1/1] nvme-rdma: Add association between ctrl and transport dev
Date: Thu, 23 May 2019 17:33:23 +0200 [thread overview]
Message-ID: <20190523153323.GA21083@lst.de> (raw)
In-Reply-To: <264c1ab2-a097-3384-381f-2b8c56c4442c@mellanox.com>
On Thu, May 23, 2019@02:05:23PM +0300, Max Gurtovoy wrote:
>
> On 5/23/2019 1:22 PM, Christoph Hellwig wrote:
>>> +static void nvme_rdma_ctrl_dev_put(struct nvme_rdma_ctrl *ctrl,
>>> + struct nvme_rdma_device *dev)
>>> +{
>>> + ctrl->device = NULL;
>> double whitespace here.
> thanks.
>>
>>> + kref_put(&dev->ref, nvme_rdma_free_dev);
>>> +}
>>> +
>>> +static void nvme_rdma_ctrl_dev_get(struct nvme_rdma_ctrl *ctrl,
>>> + struct nvme_rdma_device *dev)
>>> +{
>>> + kref_get(&dev->ref);
>>> + ctrl->device = dev;
>> Why aren't these using nvme_rdma_dev_put / nvme_rdma_dev_get?
>
> Since we change the ctrl->device pointer here.
>
> Do you prefer doing it without helper ?
We can still use the helper underneath instead of open coding the kref
calls, right?
next prev parent reply other threads:[~2019-05-23 15:33 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-05-21 13:19 [PATCH 1/1] nvme-rdma: Add association between ctrl and transport dev Max Gurtovoy
2019-05-23 8:13 ` [Suspected-Phishing][PATCH " Max Gurtovoy
2019-05-23 10:22 ` [PATCH " Christoph Hellwig
2019-05-23 11:05 ` Max Gurtovoy
2019-05-23 15:33 ` Christoph Hellwig [this message]
2019-05-24 19:36 ` Max Gurtovoy
2019-05-24 7:05 ` Sagi Grimberg
2019-05-24 19:30 ` Max Gurtovoy
2019-05-24 23:05 ` Sagi Grimberg
2019-05-28 11:50 ` Max Gurtovoy
2019-05-28 19:36 ` Sagi Grimberg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190523153323.GA21083@lst.de \
--to=hch@lst.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox