Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'char-misc-4.10-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc

Pull char/misc fixes from Greg KH:
"Here are a few small char/misc driver fixes for 4.10-rc3.

Two MEI driver fixes, and three NVMEM patches for reported issues, and
a new Hyper-V driver MAINTAINER update. Nothing major at all, all have
been in linux-next with no reported issues"

* tag 'char-misc-4.10-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc:
hyper-v: Add myself as additional MAINTAINER
nvmem: fix nvmem_cell_read() return type doc
nvmem: imx-ocotp: Fix wrong register size
nvmem: qfprom: Allow single byte accesses for read/write
mei: move write cb to completion on credentials failures
mei: bus: fix mei_cldev_enable KDoc

+24 -19
+1
MAINTAINERS
··· 5965 5965 Hyper-V CORE AND DRIVERS 5966 5966 M: "K. Y. Srinivasan" <kys@microsoft.com> 5967 5967 M: Haiyang Zhang <haiyangz@microsoft.com> 5968 + M: Stephen Hemminger <sthemmin@microsoft.com> 5968 5969 L: devel@linuxdriverproject.org 5969 5970 S: Maintained 5970 5971 F: arch/x86/include/asm/mshyperv.h
+1 -1
drivers/misc/mei/bus.c
··· 450 450 EXPORT_SYMBOL_GPL(mei_cldev_enabled); 451 451 452 452 /** 453 - * mei_cldev_enable_device - enable me client device 453 + * mei_cldev_enable - enable me client device 454 454 * create connection with me client 455 455 * 456 456 * @cldev: me client device
+12 -8
drivers/misc/mei/client.c
··· 1541 1541 1542 1542 rets = first_chunk ? mei_cl_tx_flow_ctrl_creds(cl) : 1; 1543 1543 if (rets < 0) 1544 - return rets; 1544 + goto err; 1545 1545 1546 1546 if (rets == 0) { 1547 1547 cl_dbg(dev, cl, "No flow control credentials: not sending.\n"); ··· 1575 1575 cb->buf.size, cb->buf_idx); 1576 1576 1577 1577 rets = mei_write_message(dev, &mei_hdr, buf->data + cb->buf_idx); 1578 - if (rets) { 1579 - cl->status = rets; 1580 - list_move_tail(&cb->list, &cmpl_list->list); 1581 - return rets; 1582 - } 1578 + if (rets) 1579 + goto err; 1583 1580 1584 1581 cl->status = 0; 1585 1582 cl->writing_state = MEI_WRITING; ··· 1584 1587 cb->completed = mei_hdr.msg_complete == 1; 1585 1588 1586 1589 if (first_chunk) { 1587 - if (mei_cl_tx_flow_ctrl_creds_reduce(cl)) 1588 - return -EIO; 1590 + if (mei_cl_tx_flow_ctrl_creds_reduce(cl)) { 1591 + rets = -EIO; 1592 + goto err; 1593 + } 1589 1594 } 1590 1595 1591 1596 if (mei_hdr.msg_complete) 1592 1597 list_move_tail(&cb->list, &dev->write_waiting_list.list); 1593 1598 1594 1599 return 0; 1600 + 1601 + err: 1602 + cl->status = rets; 1603 + list_move_tail(&cb->list, &cmpl_list->list); 1604 + return rets; 1595 1605 } 1596 1606 1597 1607 /**
+2 -2
drivers/nvmem/core.c
··· 981 981 * @cell: nvmem cell to be read. 982 982 * @len: pointer to length of cell which will be populated on successful read. 983 983 * 984 - * Return: ERR_PTR() on error or a valid pointer to a char * buffer on success. 985 - * The buffer should be freed by the consumer with a kfree(). 984 + * Return: ERR_PTR() on error or a valid pointer to a buffer on success. The 985 + * buffer should be freed by the consumer with a kfree(). 986 986 */ 987 987 void *nvmem_cell_read(struct nvmem_cell *cell, size_t *len) 988 988 {
+1 -1
drivers/nvmem/imx-ocotp.c
··· 71 71 72 72 static const struct of_device_id imx_ocotp_dt_ids[] = { 73 73 { .compatible = "fsl,imx6q-ocotp", (void *)128 }, 74 - { .compatible = "fsl,imx6sl-ocotp", (void *)32 }, 74 + { .compatible = "fsl,imx6sl-ocotp", (void *)64 }, 75 75 { .compatible = "fsl,imx6sx-ocotp", (void *)128 }, 76 76 { }, 77 77 };
+7 -7
drivers/nvmem/qfprom.c
··· 21 21 unsigned int reg, void *_val, size_t bytes) 22 22 { 23 23 void __iomem *base = context; 24 - u32 *val = _val; 25 - int i = 0, words = bytes / 4; 24 + u8 *val = _val; 25 + int i = 0, words = bytes; 26 26 27 27 while (words--) 28 - *val++ = readl(base + reg + (i++ * 4)); 28 + *val++ = readb(base + reg + i++); 29 29 30 30 return 0; 31 31 } ··· 34 34 unsigned int reg, void *_val, size_t bytes) 35 35 { 36 36 void __iomem *base = context; 37 - u32 *val = _val; 38 - int i = 0, words = bytes / 4; 37 + u8 *val = _val; 38 + int i = 0, words = bytes; 39 39 40 40 while (words--) 41 - writel(*val++, base + reg + (i++ * 4)); 41 + writeb(*val++, base + reg + i++); 42 42 43 43 return 0; 44 44 } ··· 53 53 static struct nvmem_config econfig = { 54 54 .name = "qfprom", 55 55 .owner = THIS_MODULE, 56 - .stride = 4, 56 + .stride = 1, 57 57 .word_size = 1, 58 58 .reg_read = qfprom_reg_read, 59 59 .reg_write = qfprom_reg_write,