linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Wei Liu <wei.liu@kernel.org>
To: Rikard Falkeborn <rikard.falkeborn@gmail.com>
Cc: Joerg Roedel <joro@8bytes.org>,
	iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org,
	"K. Y. Srinivasan" <kys@microsoft.com>,
	Haiyang Zhang <haiyangz@microsoft.com>,
	Stephen Hemminger <sthemmin@microsoft.com>,
	Wei Liu <wei.liu@kernel.org>,
	linux-hyperv@vger.kernel.org
Subject: Re: [PATCH 1/2] iommu/hyper-v: Constify hyperv_ir_domain_ops
Date: Tue, 26 May 2020 10:09:01 +0100	[thread overview]
Message-ID: <20200526090901.xuzobaw2v4lapfdc@debian> (raw)
In-Reply-To: <20200525214958.30015-2-rikard.falkeborn@gmail.com>

On Mon, May 25, 2020 at 11:49:57PM +0200, Rikard Falkeborn wrote:
> The struct hyperv_ir_domain_ops is not modified and can be made const to
> allow the compiler to put it in read-only memory.
> 
> Before:
>    text    data     bss     dec     hex filename
>    2916    1180    1120    5216    1460 drivers/iommu/hyperv-iommu.o
> 
> After:
>    text    data     bss     dec     hex filename
>    3044    1052    1120    5216    1460 drivers/iommu/hyperv-iommu.o
> 
> Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com>

Acked-by: Wei Liu <wei.liu@kernel.org>

> ---
>  drivers/iommu/hyperv-iommu.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iommu/hyperv-iommu.c b/drivers/iommu/hyperv-iommu.c
> index a386b83e0e34..3c0c67a99c7b 100644
> --- a/drivers/iommu/hyperv-iommu.c
> +++ b/drivers/iommu/hyperv-iommu.c
> @@ -131,7 +131,7 @@ static int hyperv_irq_remapping_activate(struct irq_domain *domain,
>  	return 0;
>  }
>  
> -static struct irq_domain_ops hyperv_ir_domain_ops = {
> +static const struct irq_domain_ops hyperv_ir_domain_ops = {
>  	.alloc = hyperv_irq_remapping_alloc,
>  	.free = hyperv_irq_remapping_free,
>  	.activate = hyperv_irq_remapping_activate,
> -- 
> 2.26.2
> 

  reply	other threads:[~2020-05-26  9:09 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-25 21:49 [PATCH 0/2] drivers/iommu: Constify structs Rikard Falkeborn
2020-05-25 21:49 ` [PATCH 1/2] iommu/hyper-v: Constify hyperv_ir_domain_ops Rikard Falkeborn
2020-05-26  9:09   ` Wei Liu [this message]
2020-05-25 21:49 ` [PATCH 2/2] iommu/sun50i: Constify sun50i_iommu_ops Rikard Falkeborn
2020-05-26  7:56   ` Maxime Ripard
2020-05-27 12:39 ` [PATCH 0/2] drivers/iommu: Constify structs Joerg Roedel

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=20200526090901.xuzobaw2v4lapfdc@debian \
    --to=wei.liu@kernel.org \
    --cc=haiyangz@microsoft.com \
    --cc=iommu@lists.linux-foundation.org \
    --cc=joro@8bytes.org \
    --cc=kys@microsoft.com \
    --cc=linux-hyperv@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rikard.falkeborn@gmail.com \
    --cc=sthemmin@microsoft.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;
as well as URLs for NNTP newsgroup(s).