Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e65ac4d5 authored by David S. Miller's avatar David S. Miller
Browse files


Pull in the 'net' tree to get CAIF bug fixes upon which
the following set of CAIF feature patches depend.

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 816a7854 d62f8dbb
Loading
Loading
Loading
Loading
+5 −4
Original line number Diff line number Diff line
@@ -744,14 +744,14 @@ static void cfhsi_wake_up(struct work_struct *work)
		size_t fifo_occupancy = 0;

		/* Wakeup timeout */
		dev_err(&cfhsi->ndev->dev, "%s: Timeout.\n",
		dev_dbg(&cfhsi->ndev->dev, "%s: Timeout.\n",
			__func__);

		/* Check FIFO to check if modem has sent something. */
		WARN_ON(cfhsi->dev->cfhsi_fifo_occupancy(cfhsi->dev,
					&fifo_occupancy));

		dev_err(&cfhsi->ndev->dev, "%s: Bytes in FIFO: %u.\n",
		dev_dbg(&cfhsi->ndev->dev, "%s: Bytes in FIFO: %u.\n",
				__func__, (unsigned) fifo_occupancy);

		/* Check if we misssed the interrupt. */
@@ -1210,7 +1210,7 @@ int cfhsi_probe(struct platform_device *pdev)

static void cfhsi_shutdown(struct cfhsi *cfhsi)
{
	u8 *tx_buf, *rx_buf;
	u8 *tx_buf, *rx_buf, *flip_buf;

	/* Stop TXing */
	netif_tx_stop_all_queues(cfhsi->ndev);
@@ -1234,7 +1234,7 @@ static void cfhsi_shutdown(struct cfhsi *cfhsi)
	/* Store bufferes: will be freed later. */
	tx_buf = cfhsi->tx_buf;
	rx_buf = cfhsi->rx_buf;

	flip_buf = cfhsi->rx_flip_buf;
	/* Flush transmit queues. */
	cfhsi_abort_tx(cfhsi);

@@ -1247,6 +1247,7 @@ static void cfhsi_shutdown(struct cfhsi *cfhsi)
	/* Free buffers. */
	kfree(tx_buf);
	kfree(rx_buf);
	kfree(flip_buf);
}

int cfhsi_remove(struct platform_device *pdev)
+2 −3
Original line number Diff line number Diff line
@@ -626,7 +626,7 @@ static netdev_tx_t start_xmit(struct sk_buff *skb, struct net_device *dev)
	/* This can happen with OOM and indirect buffers. */
	if (unlikely(capacity < 0)) {
		if (likely(capacity == -ENOMEM)) {
			if (net_ratelimit()) {
			if (net_ratelimit())
				dev_warn(&dev->dev,
					 "TX queue failure: out of memory\n");
		} else {
@@ -636,7 +636,6 @@ static netdev_tx_t start_xmit(struct sk_buff *skb, struct net_device *dev)
					 "Unexpected TX queue failure: %d\n",
					 capacity);
		}
		}
		dev->stats.tx_dropped++;
		kfree_skb(skb);
		return NETDEV_TX_OK;
+6 −3
Original line number Diff line number Diff line
@@ -103,6 +103,7 @@ static int chnl_recv_cb(struct cflayer *layr, struct cfpkt *pkt)
		skb->protocol = htons(ETH_P_IPV6);
		break;
	default:
		kfree_skb(skb);
		priv->netdev->stats.rx_errors++;
		return -EINVAL;
	}
@@ -220,14 +221,16 @@ static int chnl_net_start_xmit(struct sk_buff *skb, struct net_device *dev)

	if (skb->len > priv->netdev->mtu) {
		pr_warn("Size of skb exceeded MTU\n");
		kfree_skb(skb);
		dev->stats.tx_errors++;
		return -ENOSPC;
		return NETDEV_TX_OK;
	}

	if (!priv->flowenabled) {
		pr_debug("dropping packets flow off\n");
		kfree_skb(skb);
		dev->stats.tx_dropped++;
		return NETDEV_TX_BUSY;
		return NETDEV_TX_OK;
	}

	if (priv->conn_req.protocol == CAIFPROTO_DATAGRAM_LOOP)
@@ -242,7 +245,7 @@ static int chnl_net_start_xmit(struct sk_buff *skb, struct net_device *dev)
	result = priv->chnl.dn->transmit(priv->chnl.dn, pkt);
	if (result) {
		dev->stats.tx_dropped++;
		return result;
		return NETDEV_TX_OK;
	}

	/* Update statistics. */
+20 −0
Original line number Diff line number Diff line
@@ -1409,14 +1409,34 @@ EXPORT_SYMBOL(register_netdevice_notifier);
 *	register_netdevice_notifier(). The notifier is unlinked into the
 *	kernel structures and may then be reused. A negative errno code
 *	is returned on a failure.
 *
 * 	After unregistering unregister and down device events are synthesized
 *	for all devices on the device list to the removed notifier to remove
 *	the need for special case cleanup code.
 */

int unregister_netdevice_notifier(struct notifier_block *nb)
{
	struct net_device *dev;
	struct net *net;
	int err;

	rtnl_lock();
	err = raw_notifier_chain_unregister(&netdev_chain, nb);
	if (err)
		goto unlock;

	for_each_net(net) {
		for_each_netdev(net, dev) {
			if (dev->flags & IFF_UP) {
				nb->notifier_call(nb, NETDEV_GOING_DOWN, dev);
				nb->notifier_call(nb, NETDEV_DOWN, dev);
			}
			nb->notifier_call(nb, NETDEV_UNREGISTER, dev);
			nb->notifier_call(nb, NETDEV_UNREGISTER_BATCH, dev);
		}
	}
unlock:
	rtnl_unlock();
	return err;
}
+1 −1
Original line number Diff line number Diff line
@@ -3480,7 +3480,7 @@ static int pfkey_send_migrate(const struct xfrm_selector *sel, u8 dir, u8 type,

	/* Addresses to be used by KM for negotiation, if ext is available */
	if (k != NULL && (set_sadb_kmaddress(skb, k) < 0))
		return -EINVAL;
		goto err;

	/* selector src */
	set_sadb_address(skb, sasize_sel, SADB_EXT_ADDRESS_SRC, sel);
Loading