Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751523AbdF1KCG (ORCPT ); Wed, 28 Jun 2017 06:02:06 -0400 Received: from mail-pg0-f66.google.com ([74.125.83.66]:33031 "EHLO mail-pg0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751489AbdF1KCB (ORCPT ); Wed, 28 Jun 2017 06:02:01 -0400 Subject: Re: [PATCH] iommu/vt-d: constify intel_dma_ops. To: Joerg Roedel References: <20170628085318.GB14532@8bytes.org> Cc: dwmw2@infradead.org, iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org From: Arvind Yadav Message-ID: <0868ed89-f9f2-1983-ea63-2e391142b44b@gmail.com> Date: Wed, 28 Jun 2017 15:31:16 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.5.1 MIME-Version: 1.0 In-Reply-To: <20170628085318.GB14532@8bytes.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 815 Lines: 26 Hi, Most dma_map_ops structures are never modified. Constify these structures such that these can be write-protected. This file size diff will show the difference between data and text segment. Thanks, ~arvind On Wednesday 28 June 2017 02:23 PM, Joerg Roedel wrote: > On Tue, Jun 13, 2017 at 03:48:34PM +0530, Arvind Yadav wrote: >> File size before: >> text data bss dec hex filename >> 32765 758 1824 35347 8a13 drivers/iommu/intel-iommu.o >> >> File size After adding 'const': >> text data bss dec hex filename >> 32925 598 1824 35347 8a13 drivers/iommu/intel-iommu.o > What is the point of those commit-messages? They just show that the > struct moved from data to the text segment. The overall size doesn't > change much. > > > > Joerg >