[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH net-next V2 1/2] xen-netback: split event channels support for Xen backend driver



>>> On 21.05.13 at 20:35, Wei Liu <wei.liu2@xxxxxxxxxx> wrote:
> @@ -158,4 +163,6 @@ void xenvif_carrier_off(struct xenvif *vif);
>  /* Returns number of ring slots required to send an skb to the frontend */
>  unsigned int xen_netbk_count_skb_slots(struct xenvif *vif, struct sk_buff 
> *skb);
>  
> +extern unsigned int feature_split_event_channels;

This gets used exclusively as a boolean, so ought to be bool.

> --- a/drivers/net/xen-netback/xenbus.c
> +++ b/drivers/net/xen-netback/xenbus.c
> @@ -114,6 +114,15 @@ static int netback_probe(struct xenbus_device *dev,
>                       goto abort_transaction;
>               }
>  
> +             /* Split event channels support */
> +             err = xenbus_printf(xbt, dev->nodename,
> +                             "feature-split-event-channels",
> +                             "%u", feature_split_event_channels);
> +             if (err) {
> +                     message = "writing feature-split-event-channels";
> +                     goto abort_transaction;

We had this discussion elsewhere quite recently: Failure to write
extension nodes should not be fatal - this needs to even be moved
out of the containing loop afaict.

> +     /* Try split event channels first, then single event channel. */
> +     err = xenbus_gather(XBT_NIL, dev->otherend,
> +                         "event-channel-tx", "%u", &tx_evtchn,
> +                         "event-channel-rx", "%u", &rx_evtchn, NULL);
> +     if (err) {
> +             err = xenbus_gather(XBT_NIL, dev->otherend,
> +                                 "event-channel", "%u", &tx_evtchn, NULL);

And this got discussed quite recently too: Single item reads should
use xenbus_scanf() as being the simpler interface doing better type
checking.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.