Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932464AbbFIFap (ORCPT ); Tue, 9 Jun 2015 01:30:45 -0400 Received: from mga01.intel.com ([192.55.52.88]:55054 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753608AbbFIFaM (ORCPT ); Tue, 9 Jun 2015 01:30:12 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,577,1427785200"; d="scan'208";a="743414919" From: Feng Wu To: joro@8bytes.org, dwmw2@infradead.org, tglx@linutronix.de Cc: jiang.liu@linux.intel.com, iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org Subject: [v10 03/10] iommu: dmar: Provide helper to copy shared irte fields Date: Tue, 9 Jun 2015 13:20:30 +0800 Message-Id: <1433827237-3382-4-git-send-email-feng.wu@intel.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1433827237-3382-1-git-send-email-feng.wu@intel.com> References: <1433827237-3382-1-git-send-email-feng.wu@intel.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1044 Lines: 41 From: Thomas Gleixner Instead of open coding, provide a helper function to copy the shared irte fields. Signed-off-by: Thomas Gleixner --- include/linux/dmar.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/include/linux/dmar.h b/include/linux/dmar.h index 0dbcabc..e9bc929 100644 --- a/include/linux/dmar.h +++ b/include/linux/dmar.h @@ -249,6 +249,18 @@ struct irte { }; }; +static inline void dmar_copy_shared_irte(struct irte *dst, struct irte *src) +{ + dst->present = src->present; + dst->fpd = src->fpd; + dst->avail = src->avail; + dst->pst = src->pst; + dst->vector = src->vector; + dst->sid = src->sid; + dst->sq = src->sq; + dst->svt = src->svt; +} + #define PDA_LOW_BIT 26 #define PDA_HIGH_BIT 32 -- 2.1.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/