mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Michal Simek <michal.simek@amd.com>
To: Ben Levinsky <ben.levinsky@amd.com>,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, jassisinghbrar@gmail.com
Subject: Re: [PATCH v2] mailbox: zynqmp-ipi: Make polling period configurable
Date: Fri, 19 Jul 2024 07:06:44 +0200	[thread overview]
Message-ID: <63270710-ac43-40e9-b5ac-36588bb2cc9d@amd.com> (raw)
In-Reply-To: <20240718204057.307655-1-ben.levinsky@amd.com>



On 7/18/24 22:40, Ben Levinsky wrote:
> There are cases where remote that is acking mailbox message can take longer
> than the default tx_poll_period value. Therefore, enable this to be mutable.
> 
> Added tx_poll_period field while inserting the module to set the
> poll period for ack after sending mailbox message.
> 
> Signed-off-by: Ben Levinsky <ben.levinsky@amd.com>
> ---
> v2: Made param a module_param_named mutable arg as opposed to compiled option
> ---
>   drivers/mailbox/zynqmp-ipi-mailbox.c | 9 ++++++++-
>   1 file changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/mailbox/zynqmp-ipi-mailbox.c b/drivers/mailbox/zynqmp-ipi-mailbox.c
> index 4acf5612487c..521d08b9ab47 100644
> --- a/drivers/mailbox/zynqmp-ipi-mailbox.c
> +++ b/drivers/mailbox/zynqmp-ipi-mailbox.c
> @@ -64,6 +64,13 @@
>   
>   #define MAX_SGI 16
>   
> +/*
> + * Module parameters
> + */
> +static int tx_poll_period = 5;
> +module_param_named(tx_poll_period, tx_poll_period, int, 0644);
> +MODULE_PARM_DESC(tx_poll_period, "Poll period waiting for ack after send.");
> +
>   /**
>    * struct zynqmp_ipi_mchan - Description of a Xilinx ZynqMP IPI mailbox channel
>    * @is_opened: indicate if the IPI channel is opened
> @@ -537,7 +544,7 @@ static int zynqmp_ipi_mbox_probe(struct zynqmp_ipi_mbox *ipi_mbox,
>   	mbox->num_chans = 2;
>   	mbox->txdone_irq = false;
>   	mbox->txdone_poll = true;
> -	mbox->txpoll_period = 5;
> +	mbox->txpoll_period = tx_poll_period;
>   	mbox->of_xlate = zynqmp_ipi_of_xlate;
>   	chans = devm_kzalloc(mdev, 2 * sizeof(*chans), GFP_KERNEL);
>   	if (!chans)

Acked-by: Michal Simek <michal.simek@amd.com>

Thanks,
Michal

      reply	other threads:[~2024-07-19  5:06 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-18 20:40 Ben Levinsky
2024-07-19  5:06 ` Michal Simek [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=63270710-ac43-40e9-b5ac-36588bb2cc9d@amd.com \
    --to=michal.simek@amd.com \
    --cc=ben.levinsky@amd.com \
    --cc=jassisinghbrar@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@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 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®