WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [linux-2.6.18-xen] netfront accel: Ensure hooks set if a

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [linux-2.6.18-xen] netfront accel: Ensure hooks set if accelerator loads before first
From: "Xen patchbot-linux-2.6.18-xen" <patchbot-linux-2.6.18-xen@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 31 Oct 2007 15:00:48 -0700
Delivery-date: Wed, 31 Oct 2007 15:02:47 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir@xxxxxxxxxxxxx>
# Date 1193765576 0
# Node ID 7ab0c1e671a2f201280beb715b97827c80086592
# Parent  f7559e350be88eca16c2884e2247a8467e516397
netfront accel: Ensure hooks set if accelerator loads before first
network interface.
Signed-off-by <kmansley@xxxxxxxxxxxxxx>
---
 drivers/xen/netfront/accel.c |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diff -r f7559e350be8 -r 7ab0c1e671a2 drivers/xen/netfront/accel.c
--- a/drivers/xen/netfront/accel.c      Tue Oct 30 17:32:02 2007 +0000
+++ b/drivers/xen/netfront/accel.c      Tue Oct 30 17:32:56 2007 +0000
@@ -131,7 +131,8 @@ static void add_accelerator_vif(struct n
  * Initialise the state to track an accelerator plugin module.
  */ 
 static int init_accelerator(const char *frontend, 
-                           struct netfront_accelerator **result)
+                           struct netfront_accelerator **result,
+                           struct netfront_accel_hooks *hooks)
 {
        struct netfront_accelerator *accelerator = 
                kmalloc(sizeof(struct netfront_accelerator), GFP_KERNEL);
@@ -154,7 +155,7 @@ static int init_accelerator(const char *
        INIT_LIST_HEAD(&accelerator->vif_states);
        spin_lock_init(&accelerator->vif_states_lock);
 
-       accelerator->hooks = NULL;
+       accelerator->hooks = hooks;
 
        accelerator->ready_for_probe = 1;
        accelerator->need_probe = NULL;
@@ -278,7 +279,7 @@ int netfront_load_accelerator(struct net
        }
 
        /* Couldn't find it, so create a new one and load the module */
-       if ((rc = init_accelerator(frontend, &accelerator)) < 0) {
+       if ((rc = init_accelerator(frontend, &accelerator, NULL)) < 0) {
                spin_unlock_irqrestore(&accelerators_lock, flags);
                return rc;
        }
@@ -451,7 +452,7 @@ int netfront_accelerator_loaded(int vers
        DPRINTK("Couldn't find matching accelerator (%s)\n",
                frontend);
 
-       init_accelerator(frontend, &accelerator);
+       init_accelerator(frontend, &accelerator, hooks);
 
        spin_unlock_irqrestore(&accelerators_lock, flags);
 

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [linux-2.6.18-xen] netfront accel: Ensure hooks set if accelerator loads before first, Xen patchbot-linux-2.6.18-xen <=