mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mahesh Rao <mahesh.rao@altera.com>
To: Greg KH <gregkh@linuxfoundation.org>, Dinh Nguyen <dinguyen@kernel.org>
Cc: linux-kernel@vger.kernel.org,
	Matthew Gerlach <matthew.gerlach@altera.com>
Subject: Re: [PATCH 3/5] firmware: stratix10-svc: Add initial support for asynchronous communication with Stratix10 service channel
Date: Fri, 22 Aug 2025 15:18:06 +0530	[thread overview]
Message-ID: <c27930bd-b2b8-4131-95f7-ff8435080c02@altera.com> (raw)
In-Reply-To: <2025081904-swapping-waving-aa5b@gregkh>

Hi Greg,

On 19-08-2025 04:38 pm, Greg KH wrote:
> On Tue, Jul 22, 2025 at 11:30:43AM -0500, Dinh Nguyen wrote:
>> From: Mahesh Rao <mahesh.rao@altera.com>
>>
>> Introduce support for asynchronous communication
>> with the Stratix10 service channel. Define new
>> structures to enable asynchronous messaging with
>> the Secure Device Manager (SDM). Add and remove
>> asynchronous support for existing channels.
>> Implement initialization and cleanup routines for
>> the asynchronous framework. Enable sending and
>> polling of messages to the SDM asynchronously.
>>
>> The new public functions added are:
>> - stratix10_svc_add_async_client: Adds an client
>>          to the service channel.
>> - stratix10_svc_remove_async_client: Removes an
>>          asynchronous client from the service
>>          channel.
>> - stratix10_svc_async_send: Sends an asynchronous
>>          message to the SDM mailbox in EL3 secure
>>          firmware.
>> - stratix10_svc_async_poll: Polls the status of an
>>          asynchronous service request in EL3 secure
>>          firmware.
>> - stratix10_svc_async_done: Marks an asynchronous
>>          transaction as complete and free's up the
>>          resources.
>>
>> These changes enhance the functionality of the
>> Stratix10 service channel by allowing for more
>> efficient and flexible communication with the
>> firmware.
>>
>> Signed-off-by: Mahesh Rao <mahesh.rao@altera.com>
>> Reviewed-by: Matthew Gerlach <matthew.gerlach@altera.com>
>> Signed-off-by: Dinh Nguyen <dinguyen@kernel.org>
>> ---
>>   drivers/firmware/stratix10-svc.c              | 657 +++++++++++++++++-
>>   include/linux/firmware/intel/stratix10-smc.h  |  24 +
>>   .../firmware/intel/stratix10-svc-client.h     |  88 +++
>>   3 files changed, 765 insertions(+), 4 deletions(-)
>>
>> diff --git a/drivers/firmware/stratix10-svc.c b/drivers/firmware/stratix10-svc.c
>> index a8c57963da99..4480ba8b2e11 100644
>> --- a/drivers/firmware/stratix10-svc.c
>> +++ b/drivers/firmware/stratix10-svc.c
>> @@ -4,9 +4,11 @@
>>    * Copyright (C) 2025, Altera Corporation
>>    */
>>   
>> +#include <linux/atomic.h>
>>   #include <linux/completion.h>
>>   #include <linux/delay.h>
>>   #include <linux/genalloc.h>
>> +#include <linux/hashtable.h>
>>   #include <linux/io.h>
>>   #include <linux/kfifo.h>
>>   #include <linux/kthread.h>
>> @@ -44,6 +46,47 @@
>>   #define STRATIX10_RSU				"stratix10-rsu"
>>   #define INTEL_FCS				"intel-fcs"
>>   
>> +/*Maximum number of SDM client IDs.*/
>> +#define MAX_SDM_CLIENT_IDS 16
>> +/*Client ID for SIP Service Version 1.*/
>> +#define SIP_SVC_V1_CLIENT_ID 0x1
>> +/*Maximum number of SDM job IDs.*/
>> +#define MAX_SDM_JOB_IDS 16
>> +/*Number of bits used for asynchronous transaction hashing.*/
>> +#define ASYNC_TRX_HASH_BITS 3
> 
> Tabs for defines to make them more readable?
> 
> And use spaces in your comments please.
> 
> 
>> +/* Total number of transaction IDs, which is a combination of
>> + * client ID and job ID.
>> + */
> 
> Wrong comment style.
> 
> I stopped reading here :(

I will fix this in the next revision.
> 
> thanks,
> 
> greg k-h


  reply	other threads:[~2025-08-22  9:48 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-22 16:30 [PATCH 1/5] firmware: stratix10-svc: Add mutex lock and unlock in stratix10 memory allocation/free Dinh Nguyen
2025-07-22 16:30 ` [PATCH 2/5] firmware: stratix10-svc: Implement ID pool management for asynchronous operations Dinh Nguyen
2025-08-19 11:07   ` Greg KH
2025-08-22  9:48     ` Mahesh Rao
2025-07-22 16:30 ` [PATCH 3/5] firmware: stratix10-svc: Add initial support for asynchronous communication with Stratix10 service channel Dinh Nguyen
2025-08-19 11:08   ` Greg KH
2025-08-22  9:48     ` Mahesh Rao [this message]
2025-07-22 16:30 ` [PATCH 4/5] firmware: stratix10-svc: Add support for RSU commands in asynchronous framework Dinh Nguyen
2025-07-22 16:30 ` [PATCH 5/5] firmware: stratix10-rsu: Migrate RSU driver to use stratix10 " Dinh Nguyen
2025-08-19 11:06 ` [PATCH 1/5] firmware: stratix10-svc: Add mutex lock and unlock in stratix10 memory allocation/free Greg KH
2025-08-22  9:47   ` Mahesh Rao
2025-08-22 11:49     ` Greg KH
2025-08-26  3:49       ` Mahesh Rao

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=c27930bd-b2b8-4131-95f7-ff8435080c02@altera.com \
    --to=mahesh.rao@altera.com \
    --cc=dinguyen@kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matthew.gerlach@altera.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®