]> git.karo-electronics.de Git - linux-beck.git/commitdiff
xen/apic/xenbus/swiotlb/pcifront/grant/tmem: Make functions or variables static.
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Tue, 21 Aug 2012 18:49:34 +0000 (14:49 -0400)
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Tue, 21 Aug 2012 18:50:03 +0000 (14:50 -0400)
There is no need for those functions/variables to be visible. Make them
static and also fix the compile warnings of this sort:

drivers/xen/<some file>.c: warning: symbol '<blah>' was not declared. Should it be static?

Some of them just require including the header file that
declares the functions.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
arch/x86/xen/apic.c
arch/x86/xen/enlighten.c
arch/x86/xen/pci-swiotlb-xen.c
arch/x86/xen/platform-pci-unplug.c
drivers/pci/xen-pcifront.c
drivers/xen/gntdev.c
drivers/xen/grant-table.c
drivers/xen/swiotlb-xen.c
drivers/xen/tmem.c
drivers/xen/xenbus/xenbus_dev_backend.c
drivers/xen/xenbus/xenbus_probe.c

index ec57bd3818a4cdeb0c45d3c3b13cc7a79db85f9b..7005ced5d1ad7ab93a3862f269855da4cf9a9171 100644 (file)
@@ -6,8 +6,9 @@
 
 #include <xen/xen.h>
 #include <xen/interface/physdev.h>
+#include "xen-ops.h"
 
-unsigned int xen_io_apic_read(unsigned apic, unsigned reg)
+static unsigned int xen_io_apic_read(unsigned apic, unsigned reg)
 {
        struct physdev_apic apic_op;
        int ret;
index ff962d4b821e5162415fa06ddf75e8c57d498b51..cb1b1914dbd38d63a826224323e334c5a8172768 100644 (file)
@@ -79,6 +79,8 @@
 #include "smp.h"
 #include "multicalls.h"
 
+#include <xen/events.h>
+
 EXPORT_SYMBOL_GPL(hypercall_page);
 
 DEFINE_PER_CPU(struct vcpu_info *, xen_vcpu);
index 967633ad98c48b262cf7739c7cdcdb7b8d79641a..2d58b3ff4faecbdb3672911747bd0c6251eb6eef 100644 (file)
@@ -8,6 +8,7 @@
 #include <xen/xen.h>
 #include <asm/iommu_table.h>
 
+#include <asm/xen/swiotlb-xen.h>
 int xen_swiotlb __read_mostly;
 
 static struct dma_map_ops xen_swiotlb_dma_ops = {
index ffcf2615640b0bd1f8e3596dbaf4d07c49d5dc51..0a7852483ffef27583fb6c4b5b7c3684c5b3847c 100644 (file)
@@ -24,6 +24,7 @@
 #include <linux/module.h>
 
 #include <xen/platform_pci.h>
+#include "xen-ops.h"
 
 #define XEN_PLATFORM_ERR_MAGIC -1
 #define XEN_PLATFORM_ERR_PROTOCOL -2
index d6cc62cb4cf7465fe22cb643fbde7a3f79f88a29..a4d901def8f282dccc66cc2ba61929eb35428671 100644 (file)
@@ -236,7 +236,7 @@ static int pcifront_bus_write(struct pci_bus *bus, unsigned int devfn,
        return errno_to_pcibios_err(do_pci_op(pdev, &op));
 }
 
-struct pci_ops pcifront_bus_ops = {
+static struct pci_ops pcifront_bus_ops = {
        .read = pcifront_bus_read,
        .write = pcifront_bus_write,
 };
index 1ffd03bf8e10dcb6b015e3e0b94a2a460f0d0dcd..163b7e985ed043f14e7236c9c9ce8ad93ac2a720 100644 (file)
@@ -445,7 +445,7 @@ static void mn_release(struct mmu_notifier *mn,
        spin_unlock(&priv->lock);
 }
 
-struct mmu_notifier_ops gntdev_mmu_ops = {
+static struct mmu_notifier_ops gntdev_mmu_ops = {
        .release                = mn_release,
        .invalidate_page        = mn_invl_page,
        .invalidate_range_start = mn_invl_range_start,
index 1d0d95e5b4469184740dfcbba8c31fed4ece2ee4..eea81cf8a2a505430169f0bd6e28e7c594f23110 100644 (file)
@@ -286,10 +286,9 @@ int gnttab_grant_foreign_access(domid_t domid, unsigned long frame,
 }
 EXPORT_SYMBOL_GPL(gnttab_grant_foreign_access);
 
-void gnttab_update_subpage_entry_v2(grant_ref_t ref, domid_t domid,
-                                   unsigned long frame, int flags,
-                                   unsigned page_off,
-                                   unsigned length)
+static void gnttab_update_subpage_entry_v2(grant_ref_t ref, domid_t domid,
+                                          unsigned long frame, int flags,
+                                          unsigned page_off, unsigned length)
 {
        gnttab_shared.v2[ref].sub_page.frame = frame;
        gnttab_shared.v2[ref].sub_page.page_off = page_off;
@@ -346,9 +345,9 @@ bool gnttab_subpage_grants_available(void)
 }
 EXPORT_SYMBOL_GPL(gnttab_subpage_grants_available);
 
-void gnttab_update_trans_entry_v2(grant_ref_t ref, domid_t domid,
-                                 int flags, domid_t trans_domid,
-                                 grant_ref_t trans_gref)
+static void gnttab_update_trans_entry_v2(grant_ref_t ref, domid_t domid,
+                                        int flags, domid_t trans_domid,
+                                        grant_ref_t trans_gref)
 {
        gnttab_shared.v2[ref].transitive.trans_domid = trans_domid;
        gnttab_shared.v2[ref].transitive.gref = trans_gref;
index 1afb4fba11b430b5b7cf0f0b16cd2afa8fb61f08..a52f3ae05d941a8a5167e66e632b89823e66c63e 100644 (file)
@@ -52,7 +52,7 @@ static unsigned long xen_io_tlb_nslabs;
  * Quick lookup value of the bus address of the IOTLB.
  */
 
-u64 start_dma_addr;
+static u64 start_dma_addr;
 
 static dma_addr_t xen_phys_to_bus(phys_addr_t paddr)
 {
index 89f264c67420c2448f9fe029e8193fa438369ae8..144564e5eb29e1ef59200fd079647656195280c8 100644 (file)
@@ -21,6 +21,7 @@
 #include <asm/xen/hypercall.h>
 #include <asm/xen/page.h>
 #include <asm/xen/hypervisor.h>
+#include <xen/tmem.h>
 
 #define TMEM_CONTROL               0
 #define TMEM_NEW_POOL              1
index be738c43104bea15dfca7422055d2f0cd79ecf9f..d730008007624b4227780457a96c77f8662c248e 100644 (file)
@@ -107,7 +107,7 @@ static int xenbus_backend_mmap(struct file *file, struct vm_area_struct *vma)
        return 0;
 }
 
-const struct file_operations xenbus_backend_fops = {
+static const struct file_operations xenbus_backend_fops = {
        .open = xenbus_backend_open,
        .mmap = xenbus_backend_mmap,
        .unlocked_ioctl = xenbus_backend_ioctl,
index b793723e724de767ad7cf9abac808548d78a21ba..91d3d6544a7b1955b2a13510d463814c94a69199 100644 (file)
@@ -324,8 +324,8 @@ static int cmp_dev(struct device *dev, void *data)
        return 0;
 }
 
-struct xenbus_device *xenbus_device_find(const char *nodename,
-                                        struct bus_type *bus)
+static struct xenbus_device *xenbus_device_find(const char *nodename,
+                                               struct bus_type *bus)
 {
        struct xb_find_info info = { .dev = NULL, .nodename = nodename };