mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Shiih-Yi Chen <shihyic@nvidia.com>,
	linux-kernel@vger.kernel.org, Mark Gross <markgross@kernel.org>,
	Vadim Pasternak <vadimp@nvidia.com>,
	platform-driver-x86@vger.kernel.org
Cc: davthompson@nvidia.com, limings@nvidia.com
Subject: Re: [PATCH v1] [v1] platform/mellanox: Fix mlxbf-tmfifo not handling all virtio CONSOLE notifictions
Date: Mon, 21 Aug 2023 12:03:59 +0200	[thread overview]
Message-ID: <6f57cd3a-f10d-d94e-d74d-685e2722d11f@redhat.com> (raw)
In-Reply-To: <20230814175313.7101-1-shihyic@nvidia.com>

Hi,

On 8/14/23 19:53, Shiih-Yi Chen wrote:
> From: shihyic <shihyic@nvidia.com>
> 
> rshim console does not show all entries of dmesg.
> 
> Fixed by setting MLXBF_TM_TX_LWM_IRQ for every CONSOLE notification. 
>  
> 
> Signed-off-by: shihyic <shihyic@nvidia.com>
> Review-by: limings@nvidia.com
> 
> ---
>  drivers/platform/mellanox/mlxbf-tmfifo.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/platform/mellanox/mlxbf-tmfifo.c b/drivers/platform/mellanox/mlxbf-tmfifo.c
> index a79318e90a13..4561b7d42412 100644
> --- a/drivers/platform/mellanox/mlxbf-tmfifo.c
> +++ b/drivers/platform/mellanox/mlxbf-tmfifo.c
> @@ -887,6 +887,8 @@ static bool mlxbf_tmfifo_virtio_notify(struct virtqueue *vq)
>  			tm_vdev = fifo->vdev[VIRTIO_ID_CONSOLE];
>  			mlxbf_tmfifo_console_output(tm_vdev, vring);
>  			spin_unlock_irqrestore(&fifo->spin_lock[0], flags);
> +			test_and_set_bit(MLXBF_TM_TX_LWM_IRQ,
> +					 &fifo->pend_events);

You are not doing anything with the test result of test_and_set_bit() here,
so I think you can just use a (cheaper) set_bit() call here ?

Regards,

Hans



>  		} else if (test_and_set_bit(MLXBF_TM_TX_LWM_IRQ,
>  					    &fifo->pend_events)) {
>  			return true;


  reply	other threads:[~2023-08-21 10:04 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-14 17:53 Shiih-Yi Chen
2023-08-21 10:03 ` Hans de Goede [this message]
  -- strict thread matches above, loose matches on Subject: below --
2023-08-14 17:35 Shiih-Yi Chen

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=6f57cd3a-f10d-d94e-d74d-685e2722d11f@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=davthompson@nvidia.com \
    --cc=limings@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=markgross@kernel.org \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=shihyic@nvidia.com \
    --cc=vadimp@nvidia.com \
    /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

all inboxes | Powered by JetHome®