Displaying 20 results from an estimated 331 matches for "define_spinlock".
2006 Mar 15
0
Zaptel compile errors on x86_64 - DEFINE_SPINLOCK???
Hi, (sorry for my mistake in not deleting the rest of the message just now)
The problem seems to be here in zaptel.c (and torisa.c)
#ifdef DEFINE_SPINLOCK
static DEFINE_SPINLOCK(zaptimerlock);
static DEFINE_SPINLOCK(bigzaplock);
#else
static spinlock_t zaptimerlock = SPIN_LOCK_UNLOCKED;
static spinlock_t bigzaplock = SPIN_LOCK_UNLOCKED;
#endif
If I remark out as follows:
//#ifdef DEFINE_SPINLOCK
//static DEFINE_SPINLOCK(zaptimerlock);
//static DEFI...
2013 Apr 06
2
[PATCH -next] virtio_console: make local symbols static
...ertions(+), 3 deletions(-)
diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c
index 13ad9b1..f73ad64 100644
--- a/drivers/char/virtio_console.c
+++ b/drivers/char/virtio_console.c
@@ -78,8 +78,8 @@ struct ports_driver_data {
};
static struct ports_driver_data pdrvdata;
-DEFINE_SPINLOCK(pdrvdata_lock);
-DECLARE_COMPLETION(early_console_added);
+static DEFINE_SPINLOCK(pdrvdata_lock);
+static DECLARE_COMPLETION(early_console_added);
/* This struct holds information that's relevant only for console ports */
struct console {
@@ -1202,7 +1202,7 @@ int __init virtio_cons_early_i...
2013 Apr 06
2
[PATCH -next] virtio_console: make local symbols static
...ertions(+), 3 deletions(-)
diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c
index 13ad9b1..f73ad64 100644
--- a/drivers/char/virtio_console.c
+++ b/drivers/char/virtio_console.c
@@ -78,8 +78,8 @@ struct ports_driver_data {
};
static struct ports_driver_data pdrvdata;
-DEFINE_SPINLOCK(pdrvdata_lock);
-DECLARE_COMPLETION(early_console_added);
+static DEFINE_SPINLOCK(pdrvdata_lock);
+static DECLARE_COMPLETION(early_console_added);
/* This struct holds information that's relevant only for console ports */
struct console {
@@ -1202,7 +1202,7 @@ int __init virtio_cons_early_i...
2020 Apr 14
0
[PATCH v2 28/33] iommu/omap: Remove orphan_dev tracking
...u.c
index 887fefcb03b4..ecc9d0829a91 100644
--- a/drivers/iommu/omap-iommu.c
+++ b/drivers/iommu/omap-iommu.c
@@ -35,15 +35,6 @@
static const struct iommu_ops omap_iommu_ops;
-struct orphan_dev {
- struct device *dev;
- struct list_head node;
-};
-
-static LIST_HEAD(orphan_dev_list);
-
-static DEFINE_SPINLOCK(orphan_lock);
-
#define to_iommu(dev) ((struct omap_iommu *)dev_get_drvdata(dev))
/* bitmap of the page sizes currently supported */
@@ -62,8 +53,6 @@ static DEFINE_SPINLOCK(orphan_lock);
static struct platform_driver omap_iommu_driver;
static struct kmem_cache *iopte_cachep;
-static int _o...
2011 Jun 01
6
[PATCH 1/1] [virt] virtio-blk: Use ida to allocate disk index
...drivers/block/virtio_blk.c
+++ b/drivers/block/virtio_blk.c
@@ -8,10 +8,14 @@
#include <linux/scatterlist.h>
#include <linux/string_helpers.h>
#include <scsi/scsi_cmnd.h>
+#include <linux/idr.h>
#define PART_BITS 4
-static int major, index;
+static int major;
+static DEFINE_SPINLOCK(vd_index_lock);
+static DEFINE_IDA(vd_index_ida);
+
struct workqueue_struct *virtblk_wq;
struct virtio_blk
@@ -23,6 +27,7 @@ struct virtio_blk
/* The disk structure for the kernel. */
struct gendisk *disk;
+ u32 index;
/* Request tracking. */
struct list_head reqs;
@@ -343,12 +348,2...
2011 Jun 01
6
[PATCH 1/1] [virt] virtio-blk: Use ida to allocate disk index
...drivers/block/virtio_blk.c
+++ b/drivers/block/virtio_blk.c
@@ -8,10 +8,14 @@
#include <linux/scatterlist.h>
#include <linux/string_helpers.h>
#include <scsi/scsi_cmnd.h>
+#include <linux/idr.h>
#define PART_BITS 4
-static int major, index;
+static int major;
+static DEFINE_SPINLOCK(vd_index_lock);
+static DEFINE_IDA(vd_index_ida);
+
struct workqueue_struct *virtblk_wq;
struct virtio_blk
@@ -23,6 +27,7 @@ struct virtio_blk
/* The disk structure for the kernel. */
struct gendisk *disk;
+ u32 index;
/* Request tracking. */
struct list_head reqs;
@@ -343,12 +348,2...
2007 Apr 18
2
[PATCH RFC] Change softlockup watchdog to ignore stolen time
...rt lockups just because there
was no timer event?
Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
diff -r b41fb9e70d72 kernel/softlockup.c
--- a/kernel/softlockup.c Thu Mar 22 16:25:15 2007 -0700
+++ b/kernel/softlockup.c Thu Mar 22 16:26:52 2007 -0700
@@ -17,9 +17,11 @@
static DEFINE_SPINLOCK(print_lock);
-static DEFINE_PER_CPU(unsigned long, touch_timestamp);
-static DEFINE_PER_CPU(unsigned long, print_timestamp);
+static DEFINE_PER_CPU(unsigned long long, touch_timestamp);
+static DEFINE_PER_CPU(unsigned long long, print_timestamp);
static DEFINE_PER_CPU(struct task_struct *, watch...
2007 Apr 18
2
[PATCH RFC] Change softlockup watchdog to ignore stolen time
...rt lockups just because there
was no timer event?
Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
diff -r b41fb9e70d72 kernel/softlockup.c
--- a/kernel/softlockup.c Thu Mar 22 16:25:15 2007 -0700
+++ b/kernel/softlockup.c Thu Mar 22 16:26:52 2007 -0700
@@ -17,9 +17,11 @@
static DEFINE_SPINLOCK(print_lock);
-static DEFINE_PER_CPU(unsigned long, touch_timestamp);
-static DEFINE_PER_CPU(unsigned long, print_timestamp);
+static DEFINE_PER_CPU(unsigned long long, touch_timestamp);
+static DEFINE_PER_CPU(unsigned long long, print_timestamp);
static DEFINE_PER_CPU(struct task_struct *, watch...
2013 May 07
1
[PATCH V2] xen/arm: implement smp_call_function
...h/x86/smp.c
+++ b/xen/arch/x86/smp.c
@@ -269,67 +269,16 @@ void smp_send_event_check_mask(const cpumask_t *mask)
send_IPI_mask(mask, EVENT_CHECK_VECTOR);
}
-/*
- * Structure and data for smp_call_function()/on_selected_cpus().
- */
-
-static void __smp_call_function_interrupt(void);
-static DEFINE_SPINLOCK(call_lock);
-static struct call_data_struct {
- void (*func) (void *info);
- void *info;
- int wait;
- cpumask_t selected;
-} call_data;
-
-void smp_call_function(
- void (*func) (void *info),
- void *info,
- int wait)
+void smp_send_call_function_mask(const cpumask_t *mask)
{...
2008 Jan 08
1
[PATCH] kvm guest balloon driver
...fine CMD_BALLOON_DEFLATE 0x2
+
+static int kvm_balloon_debug;
+
+#define DEBUG
+#ifdef DEBUG
+#define dprintk(str...) if (kvm_balloon_debug) printk(str)
+#else
+#define dprintk(str...)
+#endif
+
+static LIST_HEAD(balloon_plist);
+static LIST_HEAD(balloon_work);
+static int balloon_size = 0;
+static DEFINE_SPINLOCK(balloon_plist_lock);
+static DEFINE_SPINLOCK(balloon_queue_lock);
+
+struct virtio_balloon_hdr {
+ uint8_t cmd;
+ uint8_t status;
+};
+
+#define BALLOON_DATA_SIZE 200
+
+struct balloon_buf {
+ struct virtio_balloon_hdr hdr;
+ u8 data[BALLOON_DATA_SIZE];
+};
+
+struct balloon_work {
+ struct balloon...
2008 Jan 08
1
[PATCH] kvm guest balloon driver
...fine CMD_BALLOON_DEFLATE 0x2
+
+static int kvm_balloon_debug;
+
+#define DEBUG
+#ifdef DEBUG
+#define dprintk(str...) if (kvm_balloon_debug) printk(str)
+#else
+#define dprintk(str...)
+#endif
+
+static LIST_HEAD(balloon_plist);
+static LIST_HEAD(balloon_work);
+static int balloon_size = 0;
+static DEFINE_SPINLOCK(balloon_plist_lock);
+static DEFINE_SPINLOCK(balloon_queue_lock);
+
+struct virtio_balloon_hdr {
+ uint8_t cmd;
+ uint8_t status;
+};
+
+#define BALLOON_DATA_SIZE 200
+
+struct balloon_buf {
+ struct virtio_balloon_hdr hdr;
+ u8 data[BALLOON_DATA_SIZE];
+};
+
+struct balloon_work {
+ struct balloon...
2023 Jun 04
3
[PATCH v2 1/2] vgaarb: various coding style and comments fix
...-
include/linux/vgaarb.h | 8 +++-----
2 files changed, 18 insertions(+), 19 deletions(-)
diff --git a/drivers/pci/vgaarb.c b/drivers/pci/vgaarb.c
index 5a696078b382..e40e6e5e5f03 100644
--- a/drivers/pci/vgaarb.c
+++ b/drivers/pci/vgaarb.c
@@ -61,7 +61,6 @@ static bool vga_arbiter_used;
static DEFINE_SPINLOCK(vga_lock);
static DECLARE_WAIT_QUEUE_HEAD(vga_wait_queue);
-
static const char *vga_iostate_to_str(unsigned int iostate)
{
/* Ignore VGA_RSRC_IO and VGA_RSRC_MEM */
@@ -77,10 +76,12 @@ static const char *vga_iostate_to_str(unsigned int iostate)
return "none";
}
-static int vga...
2012 Apr 02
6
[PATCH 0 of 3] Patches for Xen 4.2 (v2).
Patches that were posted last week - with review comments
addressed.
2013 May 16
1
[RFC PATCH v2, part3 07/11] PCI, xen-pcifront: use new PCI interfaces to simplify implementation
...it_sd(struct pcifront_sd *sd,
{
sd->domain = domain;
sd->pdev = pdev;
+
+ /* Xen pci-backend doesn't export P2P bridges */
+ sd->busn_res.start = bus;
+ sd->busn_res.end = bus;
+ sd->busn_res.flags = IORESOURCE_BUS;
+ sd->busn_res.name = "PCI busn";
}
static DEFINE_SPINLOCK(pcifront_dev_lock);
@@ -441,12 +442,19 @@ static int pcifront_scan_bus(struct pcifront_device *pdev,
return 0;
}
+static void pcifront_release_sd(struct pci_host_bridge *bridge)
+{
+ struct pcifront_sd *sd = bridge->release_data;
+
+ kfree(sd);
+}
+
static int pcifront_scan_root(struct pci...
2013 May 16
1
[RFC PATCH v2, part3 07/11] PCI, xen-pcifront: use new PCI interfaces to simplify implementation
...it_sd(struct pcifront_sd *sd,
{
sd->domain = domain;
sd->pdev = pdev;
+
+ /* Xen pci-backend doesn't export P2P bridges */
+ sd->busn_res.start = bus;
+ sd->busn_res.end = bus;
+ sd->busn_res.flags = IORESOURCE_BUS;
+ sd->busn_res.name = "PCI busn";
}
static DEFINE_SPINLOCK(pcifront_dev_lock);
@@ -441,12 +442,19 @@ static int pcifront_scan_bus(struct pcifront_device *pdev,
return 0;
}
+static void pcifront_release_sd(struct pci_host_bridge *bridge)
+{
+ struct pcifront_sd *sd = bridge->release_data;
+
+ kfree(sd);
+}
+
static int pcifront_scan_root(struct pci...
2013 May 16
1
[RFC PATCH v2, part3 07/11] PCI, xen-pcifront: use new PCI interfaces to simplify implementation
...it_sd(struct pcifront_sd *sd,
{
sd->domain = domain;
sd->pdev = pdev;
+
+ /* Xen pci-backend doesn't export P2P bridges */
+ sd->busn_res.start = bus;
+ sd->busn_res.end = bus;
+ sd->busn_res.flags = IORESOURCE_BUS;
+ sd->busn_res.name = "PCI busn";
}
static DEFINE_SPINLOCK(pcifront_dev_lock);
@@ -441,12 +442,19 @@ static int pcifront_scan_bus(struct pcifront_device *pdev,
return 0;
}
+static void pcifront_release_sd(struct pci_host_bridge *bridge)
+{
+ struct pcifront_sd *sd = bridge->release_data;
+
+ kfree(sd);
+}
+
static int pcifront_scan_root(struct pci...
2019 Mar 06
0
[RFC PATCH net-next] failover: allow name change on IFF_UP slave interfaces
On 3/6/2019 1:26 PM, si-wei liu wrote:
>
>
>
> On 3/6/2019 4:04 AM, Jiri Pirko wrote:
>>> --- a/net/core/failover.c
>>> +++ b/net/core/failover.c
>>> @@ -16,6 +16,11 @@
>>>
>>> static LIST_HEAD(failover_list);
>>> static DEFINE_SPINLOCK(failover_lock);
>>> +static bool slave_rename_ok = true;
>>> +
>>> +module_param(slave_rename_ok, bool, (S_IRUGO | S_IWUSR));
>>> +MODULE_PARM_DESC(slave_rename_ok,
>>> + "If set allow renaming the slave when failover master is up");
>>...
2019 Mar 19
0
[PATCH] virtio_console: initialize vtermno value for ports
...o_console.c
+++ b/drivers/char/virtio_console.c
@@ -75,7 +75,7 @@ struct ports_driver_data {
/* All the console devices handled by this driver */
struct list_head consoles;
};
-static struct ports_driver_data pdrvdata;
+static struct ports_driver_data pdrvdata = { .next_vtermno = 1};
static DEFINE_SPINLOCK(pdrvdata_lock);
static DECLARE_COMPLETION(early_console_added);
@@ -1394,6 +1394,7 @@ static int add_port(struct ports_device *portdev, u32 id)
port->async_queue = NULL;
port->cons.ws.ws_row = port->cons.ws.ws_col = 0;
+ port->cons.vtermno = 0;
port->host_connected = port-...
2019 Mar 06
0
[RFC PATCH net-next] failover: allow name change on IFF_UP slave interfaces
...>>
>>> On 3/6/2019 4:04 AM, Jiri Pirko wrote:
>>>>> --- a/net/core/failover.c
>>>>> +++ b/net/core/failover.c
>>>>> @@ -16,6 +16,11 @@
>>>>>
>>>>> static LIST_HEAD(failover_list);
>>>>> static DEFINE_SPINLOCK(failover_lock);
>>>>> +static bool slave_rename_ok = true;
>>>>> +
>>>>> +module_param(slave_rename_ok, bool, (S_IRUGO | S_IWUSR));
>>>>> +MODULE_PARM_DESC(slave_rename_ok,
>>>>> + "If set allow renaming the slave whe...
2019 Nov 22
0
[RFC 04/13] ACPI/IORT: Add node categories
..._IOMMU_TYPE ((1 << ACPI_IORT_NODE_SMMU) | \
- (1 << ACPI_IORT_NODE_SMMU_V3))
+enum iort_node_category {
+ IORT_MSI_TYPE,
+ IORT_IOMMU_TYPE,
+};
struct iort_its_msi_chip {
struct list_head list;
@@ -38,6 +38,20 @@ struct iort_fwnode {
static LIST_HEAD(iort_fwnode_list);
static DEFINE_SPINLOCK(iort_fwnode_lock);
+static bool iort_type_matches(u8 type, enum iort_node_category category)
+{
+ switch (category) {
+ case IORT_IOMMU_TYPE:
+ return type == ACPI_IORT_NODE_SMMU ||
+ type == ACPI_IORT_NODE_SMMU_V3;
+ case IORT_MSI_TYPE:
+ return type == ACPI_IORT_NODE_ITS_GROUP;
+ defa...