This driver uses two iobase addresses, found in PCI bars 2 and 3.
Currently, the address in PCI bar 2 is saved in the private data as
'iobase1' and the address in PCI bar 3 is saved in the comedi_device
as the 'iobase'. The 'iobase' is the base address of the daq
registers (ai/ao) of the board. The 'iobase1' address is the base
address of the 8255, 8254, configuration, and interrupt registers.
Flip the saving of these base addresses. Save the address from PCI
bar 2 in the comedi_device 'iobase' and the address from PCI bar 3
in the private data as 'daqio'.
This will help with some cleanup of the 8255 module.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This driver uses two iobase addresses, found in PCI bars 2 and 3.
Currently, the address in PCI bar 3 is saved in the comedi_device as
the 'iobase' and the one in PCI bar 2 is just passed to subdev_8255_init()
as the 'iobase' parameter.
Save the PCI bar 3 address in the private data as 'daqio' and the
address from PCI bar 2 in the comedi_device as the 'iobase'.
This will help with some cleanup of the 8255 module.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This driver uses three iobase addresses, found in PCI bars 2, 3, and 4.
Currently, the address in PCI bar 2 is saved in the comedi_device as
the 'iobase', the PCI bar 3 address is saved in the private data as
'BADR3' and the one in PCI bar 4 is just passed to subdev_8255_init()
as the 'iobase' parameter.
Flip the saving of the PCI bar 2 and 4 base addresses. Save the address
from PCI bar 2 in the private data as the 'daqio' and the address from
PCI bar 4 in the comedi_device as the 'iobase'.
This will help with some cleanup of the 8255 module.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: cb_pcidas: use dev->iobase for PCI bar 3
Currently the base address of the 8254 and 8255 devices, found in
PCI bar 3, is saved in the private data as 'pacer_counter_dio'.
The 'iobase' in the comedi_device is currently unused.
Save the address from PCI bar 3 in the comedi_device and remove
the unnecessary member from the private data.
This will help with some cleanup of the 8255 module.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This exported function just does a free_irq() to release the interrupt
handler for the legacy and PCI dio200 drivers.
The legacy driver also calls comedi_legacy_detach() which would also
do the free_irq(). For that driver the just use comedi_legacy_detach()
directly for the (*detach).
For the PCI driver, add the free_irq() to the private (*datach) function.
Remove the, then unused, dio200_common_detach() function.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This member of the boardinfo is only set for the PCIE boards. Use the
'is_pcie' flag to determine if the offset needs to be shifted when
reading/writing the registers.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
staging: comedi: amplc_dio200.h: rename 'has_enhancements' in boardinfo
This member of the boardinfor is only set for the PCIE boards. For
aeshetics, rename it to 'is_pcie'.
For clarity, use this flag in the (*auto_attach) to determine if the
dio200_pcie_board_setup() function needs to be called instead of using
the switch (context_model).
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit performs a final tidying of the register map defines, bringing
them to a state that is ready for merging into addi_apci_1564.c when the
time comes. Actions performed include:
*Removes the APCI1564_ADDRESS_RANGE macro, which is no longer needed/used.
*Renames the APCI1564_DIGITAL_OP_{VCC,CC}_INTERRUPT_{ENABLE,DISABLE}
macros to shorter names which are more consistent with the digital input
interrupt macros.
*Fixes a typo in a comment (dev>iobase changed to dev->iobase).
*Renames the APCI1564_TCW_* macros to APCI1564_COUNTER_* names to more
accurately reflect that they are only offsets to counter registers (since
only the counters are offset from dev->iobase).
Signed-off-by: Chase Southwood <chase.southwood@gmail.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Cc: H Hartley Sweeten <hsweeten@visionengraver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Chase Southwood [Tue, 12 Aug 2014 02:03:19 +0000 (21:03 -0500)]
staging: comedi: addi_apci_1564: Remove in-driver watchdog support code
Starting with commit 1496e5961113 ("staging: comedi: addi_apci_1564: use
addi_watchdog module to init watchdog subdevice"), this driver uses the
addi_watchdog module to provide support for the watchdog subdevice. Any
remaining watchdog code in-driver can and should be removed.
This will also make future work on the timer and counter subdevices easier.
Signed-off-by: Chase Southwood <chase.southwood@gmail.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Cc: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
The DO config function served the purpose of configuring the diagnostic
interrupts for the board. As the driver currently does not support
diagnostic interrupts, the digital output subdevice does not need an
insn_config operation and this function can be safely removed.
Signed-off-by: Chase Southwood <chase.southwood@gmail.com> Reviewed-by: Ian Abbott <abbotti@mev.co.uk> Cc: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ramesh Basukala [Thu, 14 Aug 2014 14:11:44 +0000 (10:11 -0400)]
Staging: bmc: fix coding style warning
This is a patch to the vendorspecificextn.c that fixes coding style
warning message line over 80 characters found by checkpatch.pl script.
I am submitting this patch as required by Eudyptula Challenge.
Adrian Remonda [Sun, 10 Aug 2014 18:39:57 +0000 (20:39 +0200)]
Staging: rtl8188eu: Removed unneeded code.
This patch removes some unneeded code.
1) kzalloc() allocates 4 extra bytes so that we can align the return
value. But actually the return value is already aligned so we can
remove the + 4 and the call to N_BYTE_ALIGMENT().
2) The memset() isn't needed because kzalloc() zeroes the allocation.
Suggested-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Adrian Remonda <adrianremonda@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Jeremiah Mahler [Tue, 12 Aug 2014 07:03:44 +0000 (00:03 -0700)]
staging: rtl8192u/ieee80211: Fix sparse ieee80211_debug_init/_exit not declared warning
A sparse warning is generated about 'ieee80211_debug_init' and
'ieee80211_debug_exit' not being declared.
drivers/staging/rtl8192u/ieee80211/ieee80211_module.c:275:12: warning:
symbol 'ieee80211_debug_init' was not declared. Should it be static?
drivers/staging/rtl8192u/ieee80211/ieee80211_module.c:297:13: warning:
symbol 'ieee80211_debug_exit' was not declared. Should it be static?
These functions are used outside of this file so using static will not
work. The prototypes are given in r8192U_core.c but sparse nonetheless
still gives a warning. Fix the sparse warning by moving these
prototypes from r8192U_core.c to ieee80211.h.
Signed-off-by: Jeremiah Mahler <jmmahler@gmail.com> Cc: Joel Pelaez Jorge <joelpelaez@gmail.com> Cc: Andrea Merello <andrea.merello@gmail.com> Cc: "John W. Linville" <linville@tuxdriver.com> Cc: Joe Perches <joe@perches.com> Cc: Himangi Saraogi <himangi774@gmail.com> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com> Cc: Ana Rey <anarey@gmail.com> Cc: Chaitanya Hazarey <c@24.io> Cc: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se> Cc: Teodora Baluta <teobaluta@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ovidiu Toader [Mon, 11 Aug 2014 03:04:36 +0000 (20:04 -0700)]
drivers/staging/rtl8192u/r8192U_wx.c: fix warnings issued by sparse
This minor patch motivated by eudyptula challenge fixes the following warnings issued
by `sparse' in drivers/staging/rtl8192u/r8192U_wx.c:
.../r8192U_wx.c:27:5: warning: symbol 'rtl8180_rates' was not declared. Should it be static?
.../r8192U_wx.c:961:22: warning: symbol 'r8192_get_wireless_stats' was not declared. Should it be static?
.../r8192U_wx.c:990:24: warning: symbol 'r8192_wx_handlers_def' was not declared. Should it be static?
Greg reports that with one of the patches in his queue
there's now an unused variable warning in lnet_parse_ip2nets
for ipaddrs variable.
Apparently the warning is a false positive as in all cases where
lnet_ipaddr_enumerate can return without setting ipaddrs to something
a negative return value is returned that is then checked
before we actually use ipaddrs.
Srikrishan Malik [Mon, 11 Aug 2014 18:27:39 +0000 (23:57 +0530)]
staging: lustre: Cleanup variable declarations in mdc_enqueue()
Changes:
- move const union vars to the top
- move rc to bottom
- do not initialize req
- set lvb_type to enum member instead of 0
- change __u64 to u64
- fix inconsistant columnization
Signed-off-by: Srikrishan Malik <srikrishanmalik@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>