This is the 4.4.151 stable release
-----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAlt8+TYACgkQONu9yGCS aT4Jdg//Sh1LlucecX4jL5OCCnbYiAhzPby1xNgFkBp9zyD79PqXoKFqWtaD5Wwj B5igCImtaDhlZWZbSkwn7tDOtD6I3W+/ZP8ZSNYj+8nNbBpq31sZ6JJ9R+TPAPu0 8Vl1UPraDX/E6ywfMnL3PlSm3o9DoLSSwvuWSBjhFL1cxKVVCGz4jNJWQvv+Kffn Cm+bmVT96G3RfZGSI3okinUI6MAaIfJj4xgJhsY9Evev8BKnrXjr6jKff/kkaqsx sW5d0mXYL36pvL0G3Bxz8+HcdTlE6HcbHXKrI/x+IvVd5kyafBcdDsUizrg9ET8a +Q9EvMJQmdAVLiQykwZJzcdjyLQaxZjEG8JqTvdks1gqne3C4iSLMctvZUF321Vz AL8PkEZ1mMZJnQZe0KDgi+qZebSRjaD/nNDZ5AkACioTcbAzCU25nTVybrWcwi2X h7pHciU6R3sOcp2sQHIYIDeybn8jZgdNGuZWQe/t9tgCGY/yQfX4OdZMf+t+XFP/ bw87Tl1litOPIOMRe62WjSI6XjXqes7qaYBAphBV8zzN+skF1YNZspomaGIlKQ+8 Op2FWXlM0ODlm1N199PYZBefnX6Imd1N+KQF3Vue5JJvIbnWezvNxQQlkyTbfQkC RdJgTYadCX3gaHcL749P0vuO213FJrt/RfsYSEAeYRb/sPtnWxY= =VTS/ -----END PGP SIGNATURE----- Merge 4.4.151 into android-4.4 Changes in 4.4.151 dccp: fix undefined behavior with 'cwnd' shift in ccid2_cwnd_restart() l2tp: use sk_dst_check() to avoid race on sk->sk_dst_cache llc: use refcount_inc_not_zero() for llc_sap_find() net_sched: Fix missing res info when create new tc_index filter vsock: split dwork to avoid reinitializations net_sched: fix NULL pointer dereference when delete tcindex filter ALSA: hda - Sleep for 10ms after entering D3 on Conexant codecs ALSA: hda - Turn CX8200 into D3 as well upon reboot ALSA: vx222: Fix invalid endian conversions ALSA: virmidi: Fix too long output trigger loop ALSA: cs5535audio: Fix invalid endian conversion ALSA: hda: Correct Asrock B85M-ITX power_save blacklist entry ALSA: memalloc: Don't exceed over the requested size ALSA: vxpocket: Fix invalid endian conversions USB: serial: sierra: fix potential deadlock at close USB: option: add support for DW5821e ACPI: save NVS memory for Lenovo G50-45 ACPI / PM: save NVS memory for ASUS 1025C laptop serial: 8250_dw: always set baud rate in dw8250_set_termios x86/mm: Simplify p[g4um]d_page() macros Bluetooth: avoid killing an already killed socket isdn: Disable IIOCDBGVAR Linux 4.4.151 Change-Id: I717cee04f3c1a5c7fbacf696e0a5c32ca67aedf8 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
commit
e917467d97
24 changed files with 102 additions and 60 deletions
2
Makefile
2
Makefile
|
@ -1,6 +1,6 @@
|
||||||
VERSION = 4
|
VERSION = 4
|
||||||
PATCHLEVEL = 4
|
PATCHLEVEL = 4
|
||||||
SUBLEVEL = 150
|
SUBLEVEL = 151
|
||||||
EXTRAVERSION =
|
EXTRAVERSION =
|
||||||
NAME = Blurry Fish Butt
|
NAME = Blurry Fish Butt
|
||||||
|
|
||||||
|
|
|
@ -173,6 +173,11 @@ static inline unsigned long pud_pfn(pud_t pud)
|
||||||
return (pfn & pud_pfn_mask(pud)) >> PAGE_SHIFT;
|
return (pfn & pud_pfn_mask(pud)) >> PAGE_SHIFT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline unsigned long pgd_pfn(pgd_t pgd)
|
||||||
|
{
|
||||||
|
return (pgd_val(pgd) & PTE_PFN_MASK) >> PAGE_SHIFT;
|
||||||
|
}
|
||||||
|
|
||||||
#define pte_page(pte) pfn_to_page(pte_pfn(pte))
|
#define pte_page(pte) pfn_to_page(pte_pfn(pte))
|
||||||
|
|
||||||
static inline int pmd_large(pmd_t pte)
|
static inline int pmd_large(pmd_t pte)
|
||||||
|
@ -578,8 +583,7 @@ static inline unsigned long pmd_page_vaddr(pmd_t pmd)
|
||||||
* Currently stuck as a macro due to indirect forward reference to
|
* Currently stuck as a macro due to indirect forward reference to
|
||||||
* linux/mmzone.h's __section_mem_map_addr() definition:
|
* linux/mmzone.h's __section_mem_map_addr() definition:
|
||||||
*/
|
*/
|
||||||
#define pmd_page(pmd) \
|
#define pmd_page(pmd) pfn_to_page(pmd_pfn(pmd))
|
||||||
pfn_to_page((pmd_val(pmd) & pmd_pfn_mask(pmd)) >> PAGE_SHIFT)
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* the pmd page can be thought of an array like this: pmd_t[PTRS_PER_PMD]
|
* the pmd page can be thought of an array like this: pmd_t[PTRS_PER_PMD]
|
||||||
|
@ -647,8 +651,7 @@ static inline unsigned long pud_page_vaddr(pud_t pud)
|
||||||
* Currently stuck as a macro due to indirect forward reference to
|
* Currently stuck as a macro due to indirect forward reference to
|
||||||
* linux/mmzone.h's __section_mem_map_addr() definition:
|
* linux/mmzone.h's __section_mem_map_addr() definition:
|
||||||
*/
|
*/
|
||||||
#define pud_page(pud) \
|
#define pud_page(pud) pfn_to_page(pud_pfn(pud))
|
||||||
pfn_to_page((pud_val(pud) & pud_pfn_mask(pud)) >> PAGE_SHIFT)
|
|
||||||
|
|
||||||
/* Find an entry in the second-level page table.. */
|
/* Find an entry in the second-level page table.. */
|
||||||
static inline pmd_t *pmd_offset(pud_t *pud, unsigned long address)
|
static inline pmd_t *pmd_offset(pud_t *pud, unsigned long address)
|
||||||
|
@ -688,7 +691,7 @@ static inline unsigned long pgd_page_vaddr(pgd_t pgd)
|
||||||
* Currently stuck as a macro due to indirect forward reference to
|
* Currently stuck as a macro due to indirect forward reference to
|
||||||
* linux/mmzone.h's __section_mem_map_addr() definition:
|
* linux/mmzone.h's __section_mem_map_addr() definition:
|
||||||
*/
|
*/
|
||||||
#define pgd_page(pgd) pfn_to_page(pgd_val(pgd) >> PAGE_SHIFT)
|
#define pgd_page(pgd) pfn_to_page(pgd_pfn(pgd))
|
||||||
|
|
||||||
/* to find an entry in a page-table-directory. */
|
/* to find an entry in a page-table-directory. */
|
||||||
static inline unsigned long pud_index(unsigned long address)
|
static inline unsigned long pud_index(unsigned long address)
|
||||||
|
|
|
@ -124,6 +124,12 @@ void __init acpi_nvs_nosave_s3(void)
|
||||||
nvs_nosave_s3 = true;
|
nvs_nosave_s3 = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int __init init_nvs_save_s3(const struct dmi_system_id *d)
|
||||||
|
{
|
||||||
|
nvs_nosave_s3 = false;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ACPI 1.0 wants us to execute _PTS before suspending devices, so we allow the
|
* ACPI 1.0 wants us to execute _PTS before suspending devices, so we allow the
|
||||||
* user to request that behavior by using the 'acpi_old_suspend_ordering'
|
* user to request that behavior by using the 'acpi_old_suspend_ordering'
|
||||||
|
@ -318,6 +324,27 @@ static struct dmi_system_id acpisleep_dmi_table[] __initdata = {
|
||||||
DMI_MATCH(DMI_PRODUCT_NAME, "K54HR"),
|
DMI_MATCH(DMI_PRODUCT_NAME, "K54HR"),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
.callback = init_nvs_save_s3,
|
||||||
|
.ident = "Asus 1025C",
|
||||||
|
.matches = {
|
||||||
|
DMI_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."),
|
||||||
|
DMI_MATCH(DMI_PRODUCT_NAME, "1025C"),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
/*
|
||||||
|
* https://bugzilla.kernel.org/show_bug.cgi?id=189431
|
||||||
|
* Lenovo G50-45 is a platform later than 2012, but needs nvs memory
|
||||||
|
* saving during S3.
|
||||||
|
*/
|
||||||
|
{
|
||||||
|
.callback = init_nvs_save_s3,
|
||||||
|
.ident = "Lenovo G50-45",
|
||||||
|
.matches = {
|
||||||
|
DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
|
||||||
|
DMI_MATCH(DMI_PRODUCT_NAME, "80E3"),
|
||||||
|
},
|
||||||
|
},
|
||||||
{},
|
{},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1655,13 +1655,7 @@ isdn_ioctl(struct file *file, uint cmd, ulong arg)
|
||||||
} else
|
} else
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
case IIOCDBGVAR:
|
case IIOCDBGVAR:
|
||||||
if (arg) {
|
return -EINVAL;
|
||||||
if (copy_to_user(argp, &dev, sizeof(ulong)))
|
|
||||||
return -EFAULT;
|
|
||||||
return 0;
|
|
||||||
} else
|
|
||||||
return -EINVAL;
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
if ((cmd & IIOCDRVCTL) == IIOCDRVCTL)
|
if ((cmd & IIOCDRVCTL) == IIOCDRVCTL)
|
||||||
cmd = ((cmd >> _IOC_NRSHIFT) & _IOC_NRMASK) & ISDN_DRVIOCTL_MASK;
|
cmd = ((cmd >> _IOC_NRSHIFT) & _IOC_NRMASK) & ISDN_DRVIOCTL_MASK;
|
||||||
|
|
|
@ -224,7 +224,7 @@ static void dw8250_set_termios(struct uart_port *p, struct ktermios *termios,
|
||||||
unsigned int rate;
|
unsigned int rate;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
if (IS_ERR(d->clk) || !old)
|
if (IS_ERR(d->clk))
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
clk_disable_unprepare(d->clk);
|
clk_disable_unprepare(d->clk);
|
||||||
|
|
|
@ -199,6 +199,8 @@ static void option_instat_callback(struct urb *urb);
|
||||||
#define DELL_PRODUCT_5800_V2_MINICARD_VZW 0x8196 /* Novatel E362 */
|
#define DELL_PRODUCT_5800_V2_MINICARD_VZW 0x8196 /* Novatel E362 */
|
||||||
#define DELL_PRODUCT_5804_MINICARD_ATT 0x819b /* Novatel E371 */
|
#define DELL_PRODUCT_5804_MINICARD_ATT 0x819b /* Novatel E371 */
|
||||||
|
|
||||||
|
#define DELL_PRODUCT_5821E 0x81d7
|
||||||
|
|
||||||
#define KYOCERA_VENDOR_ID 0x0c88
|
#define KYOCERA_VENDOR_ID 0x0c88
|
||||||
#define KYOCERA_PRODUCT_KPC650 0x17da
|
#define KYOCERA_PRODUCT_KPC650 0x17da
|
||||||
#define KYOCERA_PRODUCT_KPC680 0x180a
|
#define KYOCERA_PRODUCT_KPC680 0x180a
|
||||||
|
@ -1033,6 +1035,8 @@ static const struct usb_device_id option_ids[] = {
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5800_MINICARD_VZW, 0xff, 0xff, 0xff) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5800_MINICARD_VZW, 0xff, 0xff, 0xff) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5800_V2_MINICARD_VZW, 0xff, 0xff, 0xff) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5800_V2_MINICARD_VZW, 0xff, 0xff, 0xff) },
|
||||||
{ USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5804_MINICARD_ATT, 0xff, 0xff, 0xff) },
|
{ USB_DEVICE_AND_INTERFACE_INFO(DELL_VENDOR_ID, DELL_PRODUCT_5804_MINICARD_ATT, 0xff, 0xff, 0xff) },
|
||||||
|
{ USB_DEVICE(DELL_VENDOR_ID, DELL_PRODUCT_5821E),
|
||||||
|
.driver_info = RSVD(0) | RSVD(1) | RSVD(6) },
|
||||||
{ USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_E100A) }, /* ADU-E100, ADU-310 */
|
{ USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_E100A) }, /* ADU-E100, ADU-310 */
|
||||||
{ USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_500A) },
|
{ USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_500A) },
|
||||||
{ USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_620UW) },
|
{ USB_DEVICE(ANYDATA_VENDOR_ID, ANYDATA_PRODUCT_ADU_620UW) },
|
||||||
|
|
|
@ -790,9 +790,9 @@ static void sierra_close(struct usb_serial_port *port)
|
||||||
kfree(urb->transfer_buffer);
|
kfree(urb->transfer_buffer);
|
||||||
usb_free_urb(urb);
|
usb_free_urb(urb);
|
||||||
usb_autopm_put_interface_async(serial->interface);
|
usb_autopm_put_interface_async(serial->interface);
|
||||||
spin_lock(&portdata->lock);
|
spin_lock_irq(&portdata->lock);
|
||||||
portdata->outstanding_urbs--;
|
portdata->outstanding_urbs--;
|
||||||
spin_unlock(&portdata->lock);
|
spin_unlock_irq(&portdata->lock);
|
||||||
}
|
}
|
||||||
|
|
||||||
sierra_stop_rx_urbs(port);
|
sierra_stop_rx_urbs(port);
|
||||||
|
|
|
@ -62,7 +62,8 @@ struct vsock_sock {
|
||||||
struct list_head pending_links;
|
struct list_head pending_links;
|
||||||
struct list_head accept_queue;
|
struct list_head accept_queue;
|
||||||
bool rejected;
|
bool rejected;
|
||||||
struct delayed_work dwork;
|
struct delayed_work connect_work;
|
||||||
|
struct delayed_work pending_work;
|
||||||
u32 peer_shutdown;
|
u32 peer_shutdown;
|
||||||
bool sent_request;
|
bool sent_request;
|
||||||
bool ignore_connecting_rst;
|
bool ignore_connecting_rst;
|
||||||
|
@ -73,7 +74,6 @@ struct vsock_sock {
|
||||||
|
|
||||||
s64 vsock_stream_has_data(struct vsock_sock *vsk);
|
s64 vsock_stream_has_data(struct vsock_sock *vsk);
|
||||||
s64 vsock_stream_has_space(struct vsock_sock *vsk);
|
s64 vsock_stream_has_space(struct vsock_sock *vsk);
|
||||||
void vsock_pending_work(struct work_struct *work);
|
|
||||||
struct sock *__vsock_create(struct net *net,
|
struct sock *__vsock_create(struct net *net,
|
||||||
struct socket *sock,
|
struct socket *sock,
|
||||||
struct sock *parent,
|
struct sock *parent,
|
||||||
|
|
|
@ -116,6 +116,11 @@ static inline void llc_sap_hold(struct llc_sap *sap)
|
||||||
atomic_inc(&sap->refcnt);
|
atomic_inc(&sap->refcnt);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline bool llc_sap_hold_safe(struct llc_sap *sap)
|
||||||
|
{
|
||||||
|
return atomic_inc_not_zero(&sap->refcnt);
|
||||||
|
}
|
||||||
|
|
||||||
void llc_sap_close(struct llc_sap *sap);
|
void llc_sap_close(struct llc_sap *sap);
|
||||||
|
|
||||||
static inline void llc_sap_put(struct llc_sap *sap)
|
static inline void llc_sap_put(struct llc_sap *sap)
|
||||||
|
|
|
@ -392,7 +392,8 @@ static void sco_sock_cleanup_listen(struct sock *parent)
|
||||||
*/
|
*/
|
||||||
static void sco_sock_kill(struct sock *sk)
|
static void sco_sock_kill(struct sock *sk)
|
||||||
{
|
{
|
||||||
if (!sock_flag(sk, SOCK_ZAPPED) || sk->sk_socket)
|
if (!sock_flag(sk, SOCK_ZAPPED) || sk->sk_socket ||
|
||||||
|
sock_flag(sk, SOCK_DEAD))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
BT_DBG("sk %p state %d", sk, sk->sk_state);
|
BT_DBG("sk %p state %d", sk, sk->sk_state);
|
||||||
|
|
|
@ -228,14 +228,16 @@ static void ccid2_cwnd_restart(struct sock *sk, const u32 now)
|
||||||
struct ccid2_hc_tx_sock *hc = ccid2_hc_tx_sk(sk);
|
struct ccid2_hc_tx_sock *hc = ccid2_hc_tx_sk(sk);
|
||||||
u32 cwnd = hc->tx_cwnd, restart_cwnd,
|
u32 cwnd = hc->tx_cwnd, restart_cwnd,
|
||||||
iwnd = rfc3390_bytes_to_packets(dccp_sk(sk)->dccps_mss_cache);
|
iwnd = rfc3390_bytes_to_packets(dccp_sk(sk)->dccps_mss_cache);
|
||||||
|
s32 delta = now - hc->tx_lsndtime;
|
||||||
|
|
||||||
hc->tx_ssthresh = max(hc->tx_ssthresh, (cwnd >> 1) + (cwnd >> 2));
|
hc->tx_ssthresh = max(hc->tx_ssthresh, (cwnd >> 1) + (cwnd >> 2));
|
||||||
|
|
||||||
/* don't reduce cwnd below the initial window (IW) */
|
/* don't reduce cwnd below the initial window (IW) */
|
||||||
restart_cwnd = min(cwnd, iwnd);
|
restart_cwnd = min(cwnd, iwnd);
|
||||||
cwnd >>= (now - hc->tx_lsndtime) / hc->tx_rto;
|
|
||||||
hc->tx_cwnd = max(cwnd, restart_cwnd);
|
|
||||||
|
|
||||||
|
while ((delta -= hc->tx_rto) >= 0 && cwnd > restart_cwnd)
|
||||||
|
cwnd >>= 1;
|
||||||
|
hc->tx_cwnd = max(cwnd, restart_cwnd);
|
||||||
hc->tx_cwnd_stamp = now;
|
hc->tx_cwnd_stamp = now;
|
||||||
hc->tx_cwnd_used = 0;
|
hc->tx_cwnd_used = 0;
|
||||||
|
|
||||||
|
|
|
@ -1145,7 +1145,7 @@ int l2tp_xmit_skb(struct l2tp_session *session, struct sk_buff *skb, int hdr_len
|
||||||
|
|
||||||
/* Get routing info from the tunnel socket */
|
/* Get routing info from the tunnel socket */
|
||||||
skb_dst_drop(skb);
|
skb_dst_drop(skb);
|
||||||
skb_dst_set(skb, dst_clone(__sk_dst_check(sk, 0)));
|
skb_dst_set(skb, sk_dst_check(sk, 0));
|
||||||
|
|
||||||
inet = inet_sk(sk);
|
inet = inet_sk(sk);
|
||||||
fl = &inet->cork.fl;
|
fl = &inet->cork.fl;
|
||||||
|
|
|
@ -73,8 +73,8 @@ struct llc_sap *llc_sap_find(unsigned char sap_value)
|
||||||
|
|
||||||
rcu_read_lock_bh();
|
rcu_read_lock_bh();
|
||||||
sap = __llc_sap_find(sap_value);
|
sap = __llc_sap_find(sap_value);
|
||||||
if (sap)
|
if (!sap || !llc_sap_hold_safe(sap))
|
||||||
llc_sap_hold(sap);
|
sap = NULL;
|
||||||
rcu_read_unlock_bh();
|
rcu_read_unlock_bh();
|
||||||
return sap;
|
return sap;
|
||||||
}
|
}
|
||||||
|
|
|
@ -382,22 +382,20 @@ tcindex_set_parms(struct net *net, struct tcf_proto *tp, unsigned long base,
|
||||||
tcf_bind_filter(tp, &cr.res, base);
|
tcf_bind_filter(tp, &cr.res, base);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (old_r)
|
|
||||||
tcf_exts_change(tp, &r->exts, &e);
|
|
||||||
else
|
|
||||||
tcf_exts_change(tp, &cr.exts, &e);
|
|
||||||
|
|
||||||
if (old_r && old_r != r)
|
if (old_r && old_r != r)
|
||||||
tcindex_filter_result_init(old_r);
|
tcindex_filter_result_init(old_r);
|
||||||
|
|
||||||
oldp = p;
|
oldp = p;
|
||||||
r->res = cr.res;
|
r->res = cr.res;
|
||||||
|
tcf_exts_change(tp, &r->exts, &e);
|
||||||
|
|
||||||
rcu_assign_pointer(tp->root, cp);
|
rcu_assign_pointer(tp->root, cp);
|
||||||
|
|
||||||
if (r == &new_filter_result) {
|
if (r == &new_filter_result) {
|
||||||
struct tcindex_filter *nfp;
|
struct tcindex_filter *nfp;
|
||||||
struct tcindex_filter __rcu **fp;
|
struct tcindex_filter __rcu **fp;
|
||||||
|
|
||||||
|
f->result.res = r->res;
|
||||||
tcf_exts_change(tp, &f->result.exts, &r->exts);
|
tcf_exts_change(tp, &f->result.exts, &r->exts);
|
||||||
|
|
||||||
fp = cp->h + (handle % cp->hash);
|
fp = cp->h + (handle % cp->hash);
|
||||||
|
|
|
@ -430,14 +430,14 @@ static int vsock_send_shutdown(struct sock *sk, int mode)
|
||||||
return transport->shutdown(vsock_sk(sk), mode);
|
return transport->shutdown(vsock_sk(sk), mode);
|
||||||
}
|
}
|
||||||
|
|
||||||
void vsock_pending_work(struct work_struct *work)
|
static void vsock_pending_work(struct work_struct *work)
|
||||||
{
|
{
|
||||||
struct sock *sk;
|
struct sock *sk;
|
||||||
struct sock *listener;
|
struct sock *listener;
|
||||||
struct vsock_sock *vsk;
|
struct vsock_sock *vsk;
|
||||||
bool cleanup;
|
bool cleanup;
|
||||||
|
|
||||||
vsk = container_of(work, struct vsock_sock, dwork.work);
|
vsk = container_of(work, struct vsock_sock, pending_work.work);
|
||||||
sk = sk_vsock(vsk);
|
sk = sk_vsock(vsk);
|
||||||
listener = vsk->listener;
|
listener = vsk->listener;
|
||||||
cleanup = true;
|
cleanup = true;
|
||||||
|
@ -477,7 +477,6 @@ out:
|
||||||
sock_put(sk);
|
sock_put(sk);
|
||||||
sock_put(listener);
|
sock_put(listener);
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(vsock_pending_work);
|
|
||||||
|
|
||||||
/**** SOCKET OPERATIONS ****/
|
/**** SOCKET OPERATIONS ****/
|
||||||
|
|
||||||
|
@ -576,6 +575,8 @@ static int __vsock_bind(struct sock *sk, struct sockaddr_vm *addr)
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void vsock_connect_timeout(struct work_struct *work);
|
||||||
|
|
||||||
struct sock *__vsock_create(struct net *net,
|
struct sock *__vsock_create(struct net *net,
|
||||||
struct socket *sock,
|
struct socket *sock,
|
||||||
struct sock *parent,
|
struct sock *parent,
|
||||||
|
@ -618,6 +619,8 @@ struct sock *__vsock_create(struct net *net,
|
||||||
vsk->sent_request = false;
|
vsk->sent_request = false;
|
||||||
vsk->ignore_connecting_rst = false;
|
vsk->ignore_connecting_rst = false;
|
||||||
vsk->peer_shutdown = 0;
|
vsk->peer_shutdown = 0;
|
||||||
|
INIT_DELAYED_WORK(&vsk->connect_work, vsock_connect_timeout);
|
||||||
|
INIT_DELAYED_WORK(&vsk->pending_work, vsock_pending_work);
|
||||||
|
|
||||||
psk = parent ? vsock_sk(parent) : NULL;
|
psk = parent ? vsock_sk(parent) : NULL;
|
||||||
if (parent) {
|
if (parent) {
|
||||||
|
@ -1094,7 +1097,7 @@ static void vsock_connect_timeout(struct work_struct *work)
|
||||||
struct sock *sk;
|
struct sock *sk;
|
||||||
struct vsock_sock *vsk;
|
struct vsock_sock *vsk;
|
||||||
|
|
||||||
vsk = container_of(work, struct vsock_sock, dwork.work);
|
vsk = container_of(work, struct vsock_sock, connect_work.work);
|
||||||
sk = sk_vsock(vsk);
|
sk = sk_vsock(vsk);
|
||||||
|
|
||||||
lock_sock(sk);
|
lock_sock(sk);
|
||||||
|
@ -1195,9 +1198,7 @@ static int vsock_stream_connect(struct socket *sock, struct sockaddr *addr,
|
||||||
* timeout fires.
|
* timeout fires.
|
||||||
*/
|
*/
|
||||||
sock_hold(sk);
|
sock_hold(sk);
|
||||||
INIT_DELAYED_WORK(&vsk->dwork,
|
schedule_delayed_work(&vsk->connect_work, timeout);
|
||||||
vsock_connect_timeout);
|
|
||||||
schedule_delayed_work(&vsk->dwork, timeout);
|
|
||||||
|
|
||||||
/* Skip ahead to preserve error code set above. */
|
/* Skip ahead to preserve error code set above. */
|
||||||
goto out_wait;
|
goto out_wait;
|
||||||
|
|
|
@ -1099,8 +1099,7 @@ static int vmci_transport_recv_listen(struct sock *sk,
|
||||||
vpending->listener = sk;
|
vpending->listener = sk;
|
||||||
sock_hold(sk);
|
sock_hold(sk);
|
||||||
sock_hold(pending);
|
sock_hold(pending);
|
||||||
INIT_DELAYED_WORK(&vpending->dwork, vsock_pending_work);
|
schedule_delayed_work(&vpending->pending_work, HZ);
|
||||||
schedule_delayed_work(&vpending->dwork, HZ);
|
|
||||||
|
|
||||||
out:
|
out:
|
||||||
return err;
|
return err;
|
||||||
|
|
|
@ -239,16 +239,12 @@ int snd_dma_alloc_pages_fallback(int type, struct device *device, size_t size,
|
||||||
int err;
|
int err;
|
||||||
|
|
||||||
while ((err = snd_dma_alloc_pages(type, device, size, dmab)) < 0) {
|
while ((err = snd_dma_alloc_pages(type, device, size, dmab)) < 0) {
|
||||||
size_t aligned_size;
|
|
||||||
if (err != -ENOMEM)
|
if (err != -ENOMEM)
|
||||||
return err;
|
return err;
|
||||||
if (size <= PAGE_SIZE)
|
if (size <= PAGE_SIZE)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
aligned_size = PAGE_SIZE << get_order(size);
|
size >>= 1;
|
||||||
if (size != aligned_size)
|
size = PAGE_SIZE << get_order(size);
|
||||||
size = aligned_size;
|
|
||||||
else
|
|
||||||
size >>= 1;
|
|
||||||
}
|
}
|
||||||
if (! dmab->area)
|
if (! dmab->area)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
|
@ -163,6 +163,7 @@ static void snd_virmidi_output_trigger(struct snd_rawmidi_substream *substream,
|
||||||
int count, res;
|
int count, res;
|
||||||
unsigned char buf[32], *pbuf;
|
unsigned char buf[32], *pbuf;
|
||||||
unsigned long flags;
|
unsigned long flags;
|
||||||
|
bool check_resched = !in_atomic();
|
||||||
|
|
||||||
if (up) {
|
if (up) {
|
||||||
vmidi->trigger = 1;
|
vmidi->trigger = 1;
|
||||||
|
@ -200,6 +201,15 @@ static void snd_virmidi_output_trigger(struct snd_rawmidi_substream *substream,
|
||||||
vmidi->event.type = SNDRV_SEQ_EVENT_NONE;
|
vmidi->event.type = SNDRV_SEQ_EVENT_NONE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (!check_resched)
|
||||||
|
continue;
|
||||||
|
/* do temporary unlock & cond_resched() for avoiding
|
||||||
|
* CPU soft lockup, which may happen via a write from
|
||||||
|
* a huge rawmidi buffer
|
||||||
|
*/
|
||||||
|
spin_unlock_irqrestore(&substream->runtime->lock, flags);
|
||||||
|
cond_resched();
|
||||||
|
spin_lock_irqsave(&substream->runtime->lock, flags);
|
||||||
}
|
}
|
||||||
out:
|
out:
|
||||||
spin_unlock_irqrestore(&substream->runtime->lock, flags);
|
spin_unlock_irqrestore(&substream->runtime->lock, flags);
|
||||||
|
|
|
@ -66,9 +66,9 @@ struct cs5535audio_dma_ops {
|
||||||
};
|
};
|
||||||
|
|
||||||
struct cs5535audio_dma_desc {
|
struct cs5535audio_dma_desc {
|
||||||
u32 addr;
|
__le32 addr;
|
||||||
u16 size;
|
__le16 size;
|
||||||
u16 ctlreserved;
|
__le16 ctlreserved;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct cs5535audio_dma {
|
struct cs5535audio_dma {
|
||||||
|
|
|
@ -158,8 +158,8 @@ static int cs5535audio_build_dma_packets(struct cs5535audio *cs5535au,
|
||||||
lastdesc->addr = cpu_to_le32((u32) dma->desc_buf.addr);
|
lastdesc->addr = cpu_to_le32((u32) dma->desc_buf.addr);
|
||||||
lastdesc->size = 0;
|
lastdesc->size = 0;
|
||||||
lastdesc->ctlreserved = cpu_to_le16(PRD_JMP);
|
lastdesc->ctlreserved = cpu_to_le16(PRD_JMP);
|
||||||
jmpprd_addr = cpu_to_le32(lastdesc->addr +
|
jmpprd_addr = (u32)dma->desc_buf.addr +
|
||||||
(sizeof(struct cs5535audio_dma_desc)*periods));
|
sizeof(struct cs5535audio_dma_desc) * periods;
|
||||||
|
|
||||||
dma->substream = substream;
|
dma->substream = substream;
|
||||||
dma->period_bytes = period_bytes;
|
dma->period_bytes = period_bytes;
|
||||||
|
|
|
@ -2069,7 +2069,7 @@ out_free:
|
||||||
*/
|
*/
|
||||||
static struct snd_pci_quirk power_save_blacklist[] = {
|
static struct snd_pci_quirk power_save_blacklist[] = {
|
||||||
/* https://bugzilla.redhat.com/show_bug.cgi?id=1525104 */
|
/* https://bugzilla.redhat.com/show_bug.cgi?id=1525104 */
|
||||||
SND_PCI_QUIRK(0x1849, 0x0c0c, "Asrock B85M-ITX", 0),
|
SND_PCI_QUIRK(0x1849, 0xc892, "Asrock B85M-ITX", 0),
|
||||||
/* https://bugzilla.redhat.com/show_bug.cgi?id=1525104 */
|
/* https://bugzilla.redhat.com/show_bug.cgi?id=1525104 */
|
||||||
SND_PCI_QUIRK(0x1043, 0x8733, "Asus Prime X370-Pro", 0),
|
SND_PCI_QUIRK(0x1043, 0x8733, "Asus Prime X370-Pro", 0),
|
||||||
/* https://bugzilla.redhat.com/show_bug.cgi?id=1572975 */
|
/* https://bugzilla.redhat.com/show_bug.cgi?id=1572975 */
|
||||||
|
|
|
@ -205,6 +205,7 @@ static void cx_auto_reboot_notify(struct hda_codec *codec)
|
||||||
struct conexant_spec *spec = codec->spec;
|
struct conexant_spec *spec = codec->spec;
|
||||||
|
|
||||||
switch (codec->core.vendor_id) {
|
switch (codec->core.vendor_id) {
|
||||||
|
case 0x14f12008: /* CX8200 */
|
||||||
case 0x14f150f2: /* CX20722 */
|
case 0x14f150f2: /* CX20722 */
|
||||||
case 0x14f150f4: /* CX20724 */
|
case 0x14f150f4: /* CX20724 */
|
||||||
break;
|
break;
|
||||||
|
@ -212,13 +213,14 @@ static void cx_auto_reboot_notify(struct hda_codec *codec)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Turn the CX20722 codec into D3 to avoid spurious noises
|
/* Turn the problematic codec into D3 to avoid spurious noises
|
||||||
from the internal speaker during (and after) reboot */
|
from the internal speaker during (and after) reboot */
|
||||||
cx_auto_turn_eapd(codec, spec->num_eapds, spec->eapds, false);
|
cx_auto_turn_eapd(codec, spec->num_eapds, spec->eapds, false);
|
||||||
|
|
||||||
snd_hda_codec_set_power_to_all(codec, codec->core.afg, AC_PWRST_D3);
|
snd_hda_codec_set_power_to_all(codec, codec->core.afg, AC_PWRST_D3);
|
||||||
snd_hda_codec_write(codec, codec->core.afg, 0,
|
snd_hda_codec_write(codec, codec->core.afg, 0,
|
||||||
AC_VERB_SET_POWER_STATE, AC_PWRST_D3);
|
AC_VERB_SET_POWER_STATE, AC_PWRST_D3);
|
||||||
|
msleep(10);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void cx_auto_free(struct hda_codec *codec)
|
static void cx_auto_free(struct hda_codec *codec)
|
||||||
|
|
|
@ -275,7 +275,7 @@ static void vx2_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
length >>= 2; /* in 32bit words */
|
length >>= 2; /* in 32bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; length > 0; length--) {
|
for (; length > 0; length--) {
|
||||||
outl(cpu_to_le32(*addr), port);
|
outl(*addr, port);
|
||||||
addr++;
|
addr++;
|
||||||
}
|
}
|
||||||
addr = (u32 *)runtime->dma_area;
|
addr = (u32 *)runtime->dma_area;
|
||||||
|
@ -285,7 +285,7 @@ static void vx2_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
count >>= 2; /* in 32bit words */
|
count >>= 2; /* in 32bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; count > 0; count--) {
|
for (; count > 0; count--) {
|
||||||
outl(cpu_to_le32(*addr), port);
|
outl(*addr, port);
|
||||||
addr++;
|
addr++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -313,7 +313,7 @@ static void vx2_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
length >>= 2; /* in 32bit words */
|
length >>= 2; /* in 32bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; length > 0; length--)
|
for (; length > 0; length--)
|
||||||
*addr++ = le32_to_cpu(inl(port));
|
*addr++ = inl(port);
|
||||||
addr = (u32 *)runtime->dma_area;
|
addr = (u32 *)runtime->dma_area;
|
||||||
pipe->hw_ptr = 0;
|
pipe->hw_ptr = 0;
|
||||||
}
|
}
|
||||||
|
@ -321,7 +321,7 @@ static void vx2_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
count >>= 2; /* in 32bit words */
|
count >>= 2; /* in 32bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; count > 0; count--)
|
for (; count > 0; count--)
|
||||||
*addr++ = le32_to_cpu(inl(port));
|
*addr++ = inl(port);
|
||||||
|
|
||||||
vx2_release_pseudo_dma(chip);
|
vx2_release_pseudo_dma(chip);
|
||||||
}
|
}
|
||||||
|
|
|
@ -375,7 +375,7 @@ static void vxp_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
length >>= 1; /* in 16bit words */
|
length >>= 1; /* in 16bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; length > 0; length--) {
|
for (; length > 0; length--) {
|
||||||
outw(cpu_to_le16(*addr), port);
|
outw(*addr, port);
|
||||||
addr++;
|
addr++;
|
||||||
}
|
}
|
||||||
addr = (unsigned short *)runtime->dma_area;
|
addr = (unsigned short *)runtime->dma_area;
|
||||||
|
@ -385,7 +385,7 @@ static void vxp_dma_write(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
count >>= 1; /* in 16bit words */
|
count >>= 1; /* in 16bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; count > 0; count--) {
|
for (; count > 0; count--) {
|
||||||
outw(cpu_to_le16(*addr), port);
|
outw(*addr, port);
|
||||||
addr++;
|
addr++;
|
||||||
}
|
}
|
||||||
vx_release_pseudo_dma(chip);
|
vx_release_pseudo_dma(chip);
|
||||||
|
@ -417,7 +417,7 @@ static void vxp_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
length >>= 1; /* in 16bit words */
|
length >>= 1; /* in 16bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; length > 0; length--)
|
for (; length > 0; length--)
|
||||||
*addr++ = le16_to_cpu(inw(port));
|
*addr++ = inw(port);
|
||||||
addr = (unsigned short *)runtime->dma_area;
|
addr = (unsigned short *)runtime->dma_area;
|
||||||
pipe->hw_ptr = 0;
|
pipe->hw_ptr = 0;
|
||||||
}
|
}
|
||||||
|
@ -425,12 +425,12 @@ static void vxp_dma_read(struct vx_core *chip, struct snd_pcm_runtime *runtime,
|
||||||
count >>= 1; /* in 16bit words */
|
count >>= 1; /* in 16bit words */
|
||||||
/* Transfer using pseudo-dma. */
|
/* Transfer using pseudo-dma. */
|
||||||
for (; count > 1; count--)
|
for (; count > 1; count--)
|
||||||
*addr++ = le16_to_cpu(inw(port));
|
*addr++ = inw(port);
|
||||||
/* Disable DMA */
|
/* Disable DMA */
|
||||||
pchip->regDIALOG &= ~VXP_DLG_DMAREAD_SEL_MASK;
|
pchip->regDIALOG &= ~VXP_DLG_DMAREAD_SEL_MASK;
|
||||||
vx_outb(chip, DIALOG, pchip->regDIALOG);
|
vx_outb(chip, DIALOG, pchip->regDIALOG);
|
||||||
/* Read the last word (16 bits) */
|
/* Read the last word (16 bits) */
|
||||||
*addr = le16_to_cpu(inw(port));
|
*addr = inw(port);
|
||||||
/* Disable 16-bit accesses */
|
/* Disable 16-bit accesses */
|
||||||
pchip->regDIALOG &= ~VXP_DLG_DMA16_SEL_MASK;
|
pchip->regDIALOG &= ~VXP_DLG_DMA16_SEL_MASK;
|
||||||
vx_outb(chip, DIALOG, pchip->regDIALOG);
|
vx_outb(chip, DIALOG, pchip->regDIALOG);
|
||||||
|
|
Loading…
Add table
Reference in a new issue