From: Mike Christie <mchristi@redhat.com>
To: target-devel@vger.kernel.org
Subject: Re: [PATCH] target/tcmu: Use macro to call container_of in tcmu_cmd_time_out_show
Date: Sat, 16 Sep 2017 00:47:08 +0000 [thread overview]
Message-ID: <59BC748C.80200@redhat.com> (raw)
In-Reply-To: <20170915054455.10615-1-nakayamakenjiro@gmail.com>
On 09/15/2017 12:44 AM, Kenjiro Nakayama wrote:
> This patch makes a tiny change that using TCMU_DEV in
> tcmu_cmd_time_out_show so it is consistent with other functions.
>
> Signed-off-by: Kenjiro Nakayama <nakayamakenjiro@gmail.com>
> ---
> drivers/target/target_core_user.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c
> index 942d094269fb..0705648acba3 100644
> --- a/drivers/target/target_core_user.c
> +++ b/drivers/target/target_core_user.c
> @@ -1734,8 +1734,7 @@ static ssize_t tcmu_cmd_time_out_show(struct config_item *item, char *page)
> {
> struct se_dev_attrib *da = container_of(to_config_group(item),
> struct se_dev_attrib, da_group);
> - struct tcmu_dev *udev = container_of(da->da_dev,
> - struct tcmu_dev, se_dev);
> + struct tcmu_dev *udev = TCMU_DEV(da->da_dev);
>
> return snprintf(page, PAGE_SIZE, "%lu\n", udev->cmd_time_out / MSEC_PER_SEC);
> }
>
Reviewed-by: Mike Christie <mchristi@redhat.com>
prev parent reply other threads:[~2017-09-16 0:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-15 5:44 [PATCH] target/tcmu: Use macro to call container_of in tcmu_cmd_time_out_show Kenjiro Nakayama
2017-09-16 0:47 ` Mike Christie [this message]
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=59BC748C.80200@redhat.com \
--to=mchristi@redhat.com \
--cc=target-devel@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.