public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c
@ 2013-12-18  6:31 Rashika Kheria
  2013-12-18  6:34 ` [PATCH 2/3] drivers: iommu: Mark functions as static in intel_irq_remapping.c Rashika Kheria
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Rashika Kheria @ 2013-12-18  6:31 UTC (permalink / raw)
  To: linux-kernel; +Cc: Joerg Roedel, iommu, josh

Mark the functions check_zero_address() and dmar_get_fault_reason() as
static in dmar.c because they are not used outside this file.

This eliminates the following warnings in dmar.c:
drivers/iommu/dmar.c:491:12: warning: no previous prototype for ‘check_zero_address’ [-Wmissing-prototypes]
drivers/iommu/dmar.c:1116:13: warning: no previous prototype for ‘dmar_get_fault_reason’ [-Wmissing-prototypes]

Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
 drivers/iommu/dmar.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/iommu/dmar.c b/drivers/iommu/dmar.c
index 8b452c9..fb35d1b 100644
--- a/drivers/iommu/dmar.c
+++ b/drivers/iommu/dmar.c
@@ -488,7 +488,7 @@ static void warn_invalid_dmar(u64 addr, const char *message)
 		dmi_get_system_info(DMI_PRODUCT_VERSION));
 }
 
-int __init check_zero_address(void)
+static int __init check_zero_address(void)
 {
 	struct acpi_table_dmar *dmar;
 	struct acpi_dmar_header *entry_header;
@@ -1113,7 +1113,7 @@ static const char *irq_remap_fault_reasons[] =
 
 #define MAX_FAULT_REASON_IDX 	(ARRAY_SIZE(fault_reason_strings) - 1)
 
-const char *dmar_get_fault_reason(u8 fault_reason, int *fault_type)
+static const char *dmar_get_fault_reason(u8 fault_reason, int *fault_type)
 {
 	if (fault_reason >= 0x20 && (fault_reason - 0x20 <
 					ARRAY_SIZE(irq_remap_fault_reasons))) {
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 2/3] drivers: iommu: Mark functions as static in intel_irq_remapping.c
  2013-12-18  6:31 [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c Rashika Kheria
@ 2013-12-18  6:34 ` Rashika Kheria
  2013-12-18  6:36 ` [PATCH 3/3] drivers: iommu: Mark function eoi_ioapic_pin_remapped() as static in irq_remapping.c Rashika Kheria
  2013-12-30 14:38 ` [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c Joerg Roedel
  2 siblings, 0 replies; 4+ messages in thread
From: Rashika Kheria @ 2013-12-18  6:34 UTC (permalink / raw)
  To: linux-kernel; +Cc: Joerg Roedel, iommu, josh

Mark functions int get_irte() and ir_dev_scope_init() as static in
intel_irq_remapping.c because they are not used outside this file.

This eliminates the following warnings in intel_irq_remapping.c:
drivers/iommu/intel_irq_remapping.c:49:5: warning: no previous prototype for ‘get_irte’ [-Wmissing-prototypes]
drivers/iommu/intel_irq_remapping.c:810:12: warning: no previous prototype for ‘ir_dev_scope_init’ [-Wmissing-prototypes]

Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
 drivers/iommu/intel_irq_remapping.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/iommu/intel_irq_remapping.c b/drivers/iommu/intel_irq_remapping.c
index bab10b1..c988b8d 100644
--- a/drivers/iommu/intel_irq_remapping.c
+++ b/drivers/iommu/intel_irq_remapping.c
@@ -46,7 +46,7 @@ static struct irq_2_iommu *irq_2_iommu(unsigned int irq)
 	return cfg ? &cfg->irq_2_iommu : NULL;
 }
 
-int get_irte(int irq, struct irte *entry)
+static int get_irte(int irq, struct irte *entry)
 {
 	struct irq_2_iommu *irq_iommu = irq_2_iommu(irq);
 	unsigned long flags;
@@ -807,7 +807,7 @@ int __init parse_ioapics_under_ir(void)
 	return 1;
 }
 
-int __init ir_dev_scope_init(void)
+static int __init ir_dev_scope_init(void)
 {
 	if (!irq_remapping_enabled)
 		return 0;
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 3/3] drivers: iommu: Mark function eoi_ioapic_pin_remapped() as static in irq_remapping.c
  2013-12-18  6:31 [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c Rashika Kheria
  2013-12-18  6:34 ` [PATCH 2/3] drivers: iommu: Mark functions as static in intel_irq_remapping.c Rashika Kheria
@ 2013-12-18  6:36 ` Rashika Kheria
  2013-12-30 14:38 ` [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c Joerg Roedel
  2 siblings, 0 replies; 4+ messages in thread
From: Rashika Kheria @ 2013-12-18  6:36 UTC (permalink / raw)
  To: linux-kernel; +Cc: Joerg Roedel, iommu, josh

Mark function eoi_ioapic_pin_remapped() as static in irq_remapping.c
because it is not used outside this file.

This eliminates the following warning in
irq_remapping.c:drivers/iommu/irq_remapping.c:153:6: warning: no
previous prototype for ‘eoi_ioapic_pin_remapped’ [-Wmissing-prototypes]

Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
---
 drivers/iommu/irq_remapping.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iommu/irq_remapping.c b/drivers/iommu/irq_remapping.c
index 39f81ae..3b05d1b 100644
--- a/drivers/iommu/irq_remapping.c
+++ b/drivers/iommu/irq_remapping.c
@@ -150,7 +150,7 @@ static int irq_remapping_setup_msi_irqs(struct pci_dev *dev,
 		return do_setup_msix_irqs(dev, nvec);
 }
 
-void eoi_ioapic_pin_remapped(int apic, int pin, int vector)
+static void eoi_ioapic_pin_remapped(int apic, int pin, int vector)
 {
 	/*
 	 * Intr-remapping uses pin number as the virtual vector
-- 
1.7.9.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c
  2013-12-18  6:31 [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c Rashika Kheria
  2013-12-18  6:34 ` [PATCH 2/3] drivers: iommu: Mark functions as static in intel_irq_remapping.c Rashika Kheria
  2013-12-18  6:36 ` [PATCH 3/3] drivers: iommu: Mark function eoi_ioapic_pin_remapped() as static in irq_remapping.c Rashika Kheria
@ 2013-12-30 14:38 ` Joerg Roedel
  2 siblings, 0 replies; 4+ messages in thread
From: Joerg Roedel @ 2013-12-30 14:38 UTC (permalink / raw)
  To: Rashika Kheria; +Cc: linux-kernel, iommu, josh

On Wed, Dec 18, 2013 at 12:01:46PM +0530, Rashika Kheria wrote:
> Mark the functions check_zero_address() and dmar_get_fault_reason() as
> static in dmar.c because they are not used outside this file.
> 
> This eliminates the following warnings in dmar.c:
> drivers/iommu/dmar.c:491:12: warning: no previous prototype for ‘check_zero_address’ [-Wmissing-prototypes]
> drivers/iommu/dmar.c:1116:13: warning: no previous prototype for ‘dmar_get_fault_reason’ [-Wmissing-prototypes]
> 
> Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com>
> Reviewed-by: Josh Triplett <josh@joshtriplett.org>

Applied all, thanks.



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-12-30 14:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-18  6:31 [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c Rashika Kheria
2013-12-18  6:34 ` [PATCH 2/3] drivers: iommu: Mark functions as static in intel_irq_remapping.c Rashika Kheria
2013-12-18  6:36 ` [PATCH 3/3] drivers: iommu: Mark function eoi_ioapic_pin_remapped() as static in irq_remapping.c Rashika Kheria
2013-12-30 14:38 ` [PATCH 1/3] drivers: iommu: Mark functions as static in dmar.c Joerg Roedel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox