Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 120007
b: refs/heads/master
c: 08d9d1c
h: refs/heads/master
i:
  120005: 63f16a5
  120003: a4e23b5
  119999: 161b27b
v: v3
  • Loading branch information
David Daney authored and Ralf Baechle committed Dec 22, 2008
1 parent cd7c404 commit df08abb
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 16 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7ef5f41c16fdddfc14e882a57200334614d8ffd6
refs/heads/master: 08d9d1c4d44ce43856da048cb0737ef769b61e9a
2 changes: 1 addition & 1 deletion trunk/arch/mips/include/asm/elf.h
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG];
*/
#ifdef __MIPSEB__
#define ELF_DATA ELFDATA2MSB
#elif __MIPSEL__
#elif defined(__MIPSEL__)
#define ELF_DATA ELFDATA2LSB
#endif
#define ELF_ARCH EM_MIPS
Expand Down
28 changes: 15 additions & 13 deletions trunk/drivers/net/ppp_generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ struct ppp {
unsigned long last_xmit; /* jiffies when last pkt sent 9c */
unsigned long last_recv; /* jiffies when last pkt rcvd a0 */
struct net_device *dev; /* network interface device a4 */
int closing; /* is device closing down? a8 */
#ifdef CONFIG_PPP_MULTILINK
int nxchan; /* next channel to send something on */
u32 nxseq; /* next sequence number to send */
Expand Down Expand Up @@ -996,7 +995,7 @@ ppp_xmit_process(struct ppp *ppp)
struct sk_buff *skb;

ppp_xmit_lock(ppp);
if (!ppp->closing) {
if (ppp->dev) {
ppp_push(ppp);
while (!ppp->xmit_pending
&& (skb = skb_dequeue(&ppp->file.xq)))
Expand Down Expand Up @@ -1464,7 +1463,8 @@ static inline void
ppp_do_recv(struct ppp *ppp, struct sk_buff *skb, struct channel *pch)
{
ppp_recv_lock(ppp);
if (!ppp->closing)
/* ppp->dev == 0 means interface is closing down */
if (ppp->dev)
ppp_receive_frame(ppp, skb, pch);
else
kfree_skb(skb);
Expand Down Expand Up @@ -2498,16 +2498,18 @@ init_ppp_file(struct ppp_file *pf, int kind)
*/
static void ppp_shutdown_interface(struct ppp *ppp)
{
struct net_device *dev;

mutex_lock(&all_ppp_mutex);
/* This will call dev_close() for us. */
ppp_lock(ppp);
if (!ppp->closing) {
ppp->closing = 1;
ppp_unlock(ppp);
unregister_netdev(ppp->dev);
} else
ppp_unlock(ppp);

dev = ppp->dev;
ppp->dev = NULL;
ppp_unlock(ppp);
/* This will call dev_close() for us. */
if (dev) {
unregister_netdev(dev);
free_netdev(dev);
}
cardmap_set(&all_ppp_units, ppp->file.index, NULL);
ppp->file.dead = 1;
ppp->owner = NULL;
Expand Down Expand Up @@ -2552,7 +2554,7 @@ static void ppp_destroy_interface(struct ppp *ppp)
if (ppp->xmit_pending)
kfree_skb(ppp->xmit_pending);

free_netdev(ppp->dev);
kfree(ppp);
}

/*
Expand Down Expand Up @@ -2614,7 +2616,7 @@ ppp_connect_channel(struct channel *pch, int unit)
if (pch->file.hdrlen > ppp->file.hdrlen)
ppp->file.hdrlen = pch->file.hdrlen;
hdrlen = pch->file.hdrlen + 2; /* for protocol bytes */
if (hdrlen > ppp->dev->hard_header_len)
if (ppp->dev && hdrlen > ppp->dev->hard_header_len)
ppp->dev->hard_header_len = hdrlen;
list_add_tail(&pch->clist, &ppp->channels);
++ppp->n_channels;
Expand Down
2 changes: 2 additions & 0 deletions trunk/net/bluetooth/rfcomm/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1786,6 +1786,8 @@ static inline void rfcomm_accept_connection(struct rfcomm_session *s)
if (err < 0)
return;

__module_get(nsock->ops->owner);

/* Set our callbacks */
nsock->sk->sk_data_ready = rfcomm_l2data_ready;
nsock->sk->sk_state_change = rfcomm_l2state_change;
Expand Down
1 change: 0 additions & 1 deletion trunk/net/socket.c
Original file line number Diff line number Diff line change
Expand Up @@ -2307,7 +2307,6 @@ int kernel_accept(struct socket *sock, struct socket **newsock, int flags)
}

(*newsock)->ops = sock->ops;
__module_get((*newsock)->ops->owner);

done:
return err;
Expand Down

0 comments on commit df08abb

Please sign in to comment.