summaryrefslogtreecommitdiffstats
path: root/drivers/mmc
diff options
context:
space:
mode:
authorIan Abbott <abbotti@mev.co.uk>2023-01-03 14:37:54 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-01-24 07:11:50 +0100
commita794e308d7674513bd02687f7317804c93a6a460 (patch)
tree084d41afe7c6065d62474564102f08489bf14aca /drivers/mmc
parent3be567d8972a8808c6d1dd0e661683ae7d437444 (diff)
downloadlinux-stable-a794e308d7674513bd02687f7317804c93a6a460.tar.gz
linux-stable-a794e308d7674513bd02687f7317804c93a6a460.tar.bz2
linux-stable-a794e308d7674513bd02687f7317804c93a6a460.zip
comedi: adv_pci1760: Fix PWM instruction handling
commit 2efb6edd52dc50273f5e68ad863dd1b1fb2f2d1c upstream. (Actually, this is fixing the "Read the Current Status" command sent to the device's outgoing mailbox, but it is only currently used for the PWM instructions.) The PCI-1760 is operated mostly by sending commands to a set of Outgoing Mailbox registers, waiting for the command to complete, and reading the result from the Incoming Mailbox registers. One of these commands is the "Read the Current Status" command. The number of this command is 0x07 (see the User's Manual for the PCI-1760 at <https://advdownload.advantech.com/productfile/Downloadfile2/1-11P6653/PCI-1760.pdf>. The `PCI1760_CMD_GET_STATUS` macro defined in the driver should expand to this command number 0x07, but unfortunately it currently expands to 0x03. (Command number 0x03 is not defined in the User's Manual.) Correct the definition of the `PCI1760_CMD_GET_STATUS` macro to fix it. This is used by all the PWM subdevice related instructions handled by `pci1760_pwm_insn_config()` which are probably all broken. The effect of sending the undefined command number 0x03 is not known. Fixes: 14b93bb6bbf0 ("staging: comedi: adv_pci_dio: separate out PCI-1760 support") Cc: <stable@vger.kernel.org> # v4.5+ Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Link: https://lore.kernel.org/r/20230103143754.17564-1-abbotti@mev.co.uk Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/mmc')
0 files changed, 0 insertions, 0 deletions