Loading drivers/char/diag/Kconfig +1 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ config DIAG_OVER_USB config DIAGFWD_BRIDGE_CODE bool "Enable QSC/9K DIAG traffic over SMUX/HSIC" depends on DIAG_CHAR depends on USB_QCOM_DIAG_BRIDGE || MSM_MHI depends on USB_QCOM_DIAG_BRIDGE || MHI_BUS default y help SMUX/HSIC Transport Layer for DIAG Router. When the MHI/SMUX endpoints Loading drivers/char/diag/Makefile +1 −1 Original line number Diff line number Diff line Loading @@ -3,4 +3,4 @@ obj-$(CONFIG_DIAG_CHAR) += diag_mux.o diag_memorydevice.o diag_usb.o diagmem.o d obj-$(CONFIG_DIAGFWD_BRIDGE_CODE) += diagfwd_bridge.o obj-$(CONFIG_USB_QCOM_DIAG_BRIDGE) += diagfwd_hsic.o obj-$(CONFIG_USB_QCOM_DIAG_BRIDGE) += diagfwd_smux.o obj-$(CONFIG_MSM_MHI) += diagfwd_mhi.o obj-$(CONFIG_MHI_BUS) += diagfwd_mhi.o drivers/char/diag/diag_dci.c +2 −6 Original line number Diff line number Diff line Loading @@ -2715,7 +2715,7 @@ static void diag_dci_init_handshake_remote(void) } } static int diag_dci_init_remote(void) int diag_dci_init_remote(void) { int i; struct dci_ops_tbl_t *temp = NULL; Loading Loading @@ -2743,7 +2743,7 @@ static int diag_dci_init_remote(void) return 0; } #else static int diag_dci_init_remote(void) int diag_dci_init_remote(void) { return 0; } Loading @@ -2756,10 +2756,6 @@ static int diag_dci_init_ops_tbl(void) err = diag_dci_init_local(); if (err) goto err; err = diag_dci_init_remote(); if (err) goto err; return 0; err: Loading drivers/char/diag/diag_dci.h +2 −1 Original line number Diff line number Diff line /* Copyright (c) 2012-2017, The Linux Foundation. All rights reserved. /* Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -323,6 +323,7 @@ unsigned char *dci_get_buffer_from_bridge(int token); int diag_dci_write_bridge(int token, unsigned char *buf, int len); int diag_dci_write_done_bridge(int index, unsigned char *buf, int len); int diag_dci_send_handshake_pkt(int index); int diag_dci_init_remote(void); #endif #endif drivers/char/diag/diag_debugfs.c +6 −8 Original line number Diff line number Diff line /* Copyright (c) 2011-2017, The Linux Foundation. All rights reserved. /* Copyright (c) 2011-2018, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading @@ -25,7 +25,7 @@ #include "diagfwd_hsic.h" #include "diagfwd_smux.h" #endif #ifdef CONFIG_MSM_MHI #ifdef CONFIG_MHI_BUS #include "diagfwd_mhi.h" #endif #include "diagmem.h" Loading Loading @@ -789,7 +789,7 @@ const struct file_operations diag_dbgfs_hsicinfo_ops = { .read = diag_dbgfs_read_hsicinfo, }; #endif #ifdef CONFIG_MSM_MHI #ifdef CONFIG_MHI_BUS static ssize_t diag_dbgfs_read_mhiinfo(struct file *file, char __user *ubuf, size_t count, loff_t *ppos) { Loading Loading @@ -821,24 +821,22 @@ static ssize_t diag_dbgfs_read_mhiinfo(struct file *file, char __user *ubuf, bytes_written = scnprintf(buf+bytes_in_buffer, bytes_remaining, "id: %d\n" "name: %s\n" "enabled %d\n" "bridge index: %s\n" "mempool: %s\n" "read ch opened: %d\n" "read ch hdl: %pK\n" "write ch opened: %d\n" "write ch hdl: %pK\n" "read work pending: %d\n" "read done work pending: %d\n" "open work pending: %d\n" "close work pending: %d\n\n", mhi_info->id, mhi_info->name, mhi_info->enabled, DIAG_BRIDGE_GET_NAME(mhi_info->dev_id), DIAG_MEMPOOL_GET_NAME(mhi_info->mempool), atomic_read(&mhi_info->read_ch.opened), mhi_info->read_ch.hdl, atomic_read(&mhi_info->write_ch.opened), mhi_info->write_ch.hdl, work_pending(&mhi_info->read_work), work_pending(&mhi_info->read_done_work), work_pending(&mhi_info->open_work), Loading Loading @@ -1036,7 +1034,7 @@ int diag_debugfs_init(void) if (!entry) goto err; #endif #ifdef CONFIG_MSM_MHI #ifdef CONFIG_MHI_BUS entry = debugfs_create_file("mhiinfo", 0444, diag_dbgfs_dent, 0, &diag_dbgfs_mhiinfo_ops); if (!entry) Loading Loading
drivers/char/diag/Kconfig +1 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ config DIAG_OVER_USB config DIAGFWD_BRIDGE_CODE bool "Enable QSC/9K DIAG traffic over SMUX/HSIC" depends on DIAG_CHAR depends on USB_QCOM_DIAG_BRIDGE || MSM_MHI depends on USB_QCOM_DIAG_BRIDGE || MHI_BUS default y help SMUX/HSIC Transport Layer for DIAG Router. When the MHI/SMUX endpoints Loading
drivers/char/diag/Makefile +1 −1 Original line number Diff line number Diff line Loading @@ -3,4 +3,4 @@ obj-$(CONFIG_DIAG_CHAR) += diag_mux.o diag_memorydevice.o diag_usb.o diagmem.o d obj-$(CONFIG_DIAGFWD_BRIDGE_CODE) += diagfwd_bridge.o obj-$(CONFIG_USB_QCOM_DIAG_BRIDGE) += diagfwd_hsic.o obj-$(CONFIG_USB_QCOM_DIAG_BRIDGE) += diagfwd_smux.o obj-$(CONFIG_MSM_MHI) += diagfwd_mhi.o obj-$(CONFIG_MHI_BUS) += diagfwd_mhi.o
drivers/char/diag/diag_dci.c +2 −6 Original line number Diff line number Diff line Loading @@ -2715,7 +2715,7 @@ static void diag_dci_init_handshake_remote(void) } } static int diag_dci_init_remote(void) int diag_dci_init_remote(void) { int i; struct dci_ops_tbl_t *temp = NULL; Loading Loading @@ -2743,7 +2743,7 @@ static int diag_dci_init_remote(void) return 0; } #else static int diag_dci_init_remote(void) int diag_dci_init_remote(void) { return 0; } Loading @@ -2756,10 +2756,6 @@ static int diag_dci_init_ops_tbl(void) err = diag_dci_init_local(); if (err) goto err; err = diag_dci_init_remote(); if (err) goto err; return 0; err: Loading
drivers/char/diag/diag_dci.h +2 −1 Original line number Diff line number Diff line /* Copyright (c) 2012-2017, The Linux Foundation. All rights reserved. /* Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -323,6 +323,7 @@ unsigned char *dci_get_buffer_from_bridge(int token); int diag_dci_write_bridge(int token, unsigned char *buf, int len); int diag_dci_write_done_bridge(int index, unsigned char *buf, int len); int diag_dci_send_handshake_pkt(int index); int diag_dci_init_remote(void); #endif #endif
drivers/char/diag/diag_debugfs.c +6 −8 Original line number Diff line number Diff line /* Copyright (c) 2011-2017, The Linux Foundation. All rights reserved. /* Copyright (c) 2011-2018, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading @@ -25,7 +25,7 @@ #include "diagfwd_hsic.h" #include "diagfwd_smux.h" #endif #ifdef CONFIG_MSM_MHI #ifdef CONFIG_MHI_BUS #include "diagfwd_mhi.h" #endif #include "diagmem.h" Loading Loading @@ -789,7 +789,7 @@ const struct file_operations diag_dbgfs_hsicinfo_ops = { .read = diag_dbgfs_read_hsicinfo, }; #endif #ifdef CONFIG_MSM_MHI #ifdef CONFIG_MHI_BUS static ssize_t diag_dbgfs_read_mhiinfo(struct file *file, char __user *ubuf, size_t count, loff_t *ppos) { Loading Loading @@ -821,24 +821,22 @@ static ssize_t diag_dbgfs_read_mhiinfo(struct file *file, char __user *ubuf, bytes_written = scnprintf(buf+bytes_in_buffer, bytes_remaining, "id: %d\n" "name: %s\n" "enabled %d\n" "bridge index: %s\n" "mempool: %s\n" "read ch opened: %d\n" "read ch hdl: %pK\n" "write ch opened: %d\n" "write ch hdl: %pK\n" "read work pending: %d\n" "read done work pending: %d\n" "open work pending: %d\n" "close work pending: %d\n\n", mhi_info->id, mhi_info->name, mhi_info->enabled, DIAG_BRIDGE_GET_NAME(mhi_info->dev_id), DIAG_MEMPOOL_GET_NAME(mhi_info->mempool), atomic_read(&mhi_info->read_ch.opened), mhi_info->read_ch.hdl, atomic_read(&mhi_info->write_ch.opened), mhi_info->write_ch.hdl, work_pending(&mhi_info->read_work), work_pending(&mhi_info->read_done_work), work_pending(&mhi_info->open_work), Loading Loading @@ -1036,7 +1034,7 @@ int diag_debugfs_init(void) if (!entry) goto err; #endif #ifdef CONFIG_MSM_MHI #ifdef CONFIG_MHI_BUS entry = debugfs_create_file("mhiinfo", 0444, diag_dbgfs_dent, 0, &diag_dbgfs_mhiinfo_ops); if (!entry) Loading