Ben Gilbert [Mon, 14 Dec 2015 19:32:21 +0000 (19:32 +0000)]
Staging: fbtft: Removed commented out/dead code
Deleted various commented out lines that have been replaced by write_reg()
Signed-off-by: Ben Gilbert <gillie59978@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Nizam Haider [Sun, 22 Nov 2015 04:09:26 +0000 (09:39 +0530)]
Staging: fbtft: fbtft-core: Removed unnecessary checks
The driver core clears the driver data to NULL after device_release
or on probe failure.
Signed-off-by: Nizam Haider <nijamh@cdac.in>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Christian Colic [Tue, 17 Nov 2015 12:56:31 +0000 (13:56 +0100)]
staging: fwserial: (coding-style) rewrite comparisons to NULL as "!fifo->data"
Rewrite multiple comparisons to NULL as "!fifo->data"
to fix the last coding style problems of this file.
Signed-off-by: Christian Colic <colic.christian@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Bogicevic Sasa [Fri, 13 Nov 2015 13:55:47 +0000 (14:55 +0100)]
drivers:staging:fwserial Fix No space is necessary after a cast
This fixes all "No space is necessary after a cast" messages
Signed-off-by: Bogicevic Sasa <brutallesale@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Bhumika Goyal [Tue, 2 Feb 2016 19:38:03 +0000 (01:08 +0530)]
Staging:octeon:removed blank line after {
Removed blank line after curly braces.
Found using checkpatch.pl.
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Saatvik Arya [Sun, 3 Jan 2016 17:12:40 +0000 (22:42 +0530)]
drivers: staging: octeon-usb: octeon-hcd.c: fixed coding style related warnings
fixed coding style warnings related to comment blocks
Signed-off-by: Saatvik Arya <aryasaatvik@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Luuk Paulussen [Tue, 22 Dec 2015 20:51:14 +0000 (09:51 +1300)]
staging: octeon: Fix logic for waking octeon ethernet tx queue.
Only wake tx queue when driver queue is back within bounds.
The logic here was just reenabling the queue when any buffers had been
freed. the queue was stopped whenever the length exceeded 1000
(MAX_OUT_QUEUE_DEPTH), but then was essentially immediately started again.
On a congested link, the queue length would just keep increasing up to
around 8000 (for average size packets), at which point the hardware would
start refusing the packets and they would begin to be dropped.
This prevented the qdisc layer from effectively managing and prioritising
packets, as essentially all packets were being allowed into the driver
queue and then were being dropped by the hardware.
This change only restarts the queue if the length is less than 1000
(MAX_OUT_QUEUE_DEPTH).
Reviewed-by: Kyeong Yoo <kyeong.yoo@alliedtelesis.co.nz>
Reviewed-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
Reviewed-by: Richard Laing <richard.laing@alliedtelesis.co.nz>
Signed-off-by: Luuk Paulussen <luuk.paulussen@alliedtelesis.co.nz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Hamish Martin [Mon, 21 Dec 2015 21:23:58 +0000 (10:23 +1300)]
staging: octeon-ethernet: fix TCP/UDP checksum calc
If the network portion of a frame is preceded by more than 14 bytes of
data, the checksum calculated in the HW is done over the wrong data and
is put in the wrong place.
In our use case an Octeon ethernet controller is connected to a Broadcom
switch chip. Extra data is included in the frame prior to egressing the
Octeon ethernet (i.e. 4 bytes of an 802.1Q tag, 4 bytes of a proprietary
BCM tag later stripped by the switch chip). This extra data causes the
checksum calculation to be incorrect.
The fix in this patch is to make use of the network header offset of the
skb. This enables the checksum to be calculated correctly.
This has been tested in both the configuration with the switch chip in
the egress path (as described above) and in a simple connection direct
to the wire.
Reviewed-by: Richard Laing <richard.laing@alliedtelesis.co.nz>
Reviewed-by: Tim Beale <tim.beale@alliedtelesis.co.nz>
Reviewed-by: Chris Packham <chris.packham@alliedtelesis.co.nz>
Signed-off-by: Hamish Martin <hamish.martin@alliedtelesis.co.nz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:29 +0000 (16:03 -0600)]
staging: fsl-mc: Added MSI support to the MC bus driver
Initialize/Cleanup ITS-MSI support for the MC bus driver at driver
init/exit time. Associate an MSI domain with each DPAA2 child device.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:28 +0000 (16:03 -0600)]
staging: fsl-mc: Added DPRC interrupt handler
The interrupt handler for DPRC IRQs is added. DPRC IRQs are
generated for hot plug events related to DPAA2 objects in a given
DPRC. These events include, creating/destroying DPAA2 objects in
the DPRC, changing the "plugged" state of DPAA2 objects and moving
objects between DPRCs.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:27 +0000 (16:03 -0600)]
staging: fsl-mc: Fixed bug in dprc_probe() error path
Destroy mc_io in error path in dprc_probe() only if the mc_io was
created in this function.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:26 +0000 (16:03 -0600)]
staging: fsl-mc: set MSI domain for DPRC objects
THE MSI domain associated with a root DPRC object is
obtained form the device tree. Child DPRCs inherit
the parent DPRC MSI domain.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:25 +0000 (16:03 -0600)]
staging: fsl-mc: Populate the IRQ pool for an MC bus instance
Scan the corresponding DPRC container to get total count
of IRQs needed by all its child DPAA2 objects. Then,
preallocate a set of MSI IRQs with the DPRC's ICID
(GIT-ITS device Id) to populate the the DPRC's IRQ pool.
Each child DPAA2 object in the DPRC and the DPRC object itself
will allocate their necessary MSI IRQs from the DPRC's IRQ pool,
in their driver probe function.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:24 +0000 (16:03 -0600)]
staging: fsl-mc: Changed DPRC built-in portal's mc_io to be atomic
The DPRC built-in portal's mc_io is used to send commands to the MC
to program MSIs for MC objects. This is done by the
fsl_mc_msi_write_msg() callback, which is invoked by the generic MSI
layer with interrupts disabled. As a result, the mc_io used in
fsl_mc_msi_write_msg needs to be an atomic mc_io.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:23 +0000 (16:03 -0600)]
staging: fsl-mc: Extended MC bus allocator to include IRQs
All the IRQs for DPAA2 objects in the same DPRC must use
the ICID of that DPRC, as their device Id in the GIC-ITS.
Thus, all these IRQs must share the same ITT table in the GIC.
As a result, a pool of IRQs with the same device Id must be
preallocated per DPRC (fsl-mc bus instance). So, the fsl-mc
bus object allocator is extended to also provide services
to allocate IRQs to DPAA2 devices, from their parent fsl-mc bus
IRQ pool.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:22 +0000 (16:03 -0600)]
staging: fsl-mc: Added GICv3-ITS support for FSL-MC MSIs
Added platform-specific MSI support layer for FSL-MC devices.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:21 +0000 (16:03 -0600)]
staging: fsl-mc: Added generic MSI support for FSL-MC devices
Created an MSI domain for the fsl-mc bus-- including functions
to create a domain, find a domain, alloc/free domain irqs, and
bus specific overrides for domain and irq_chip ops.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:20 +0000 (16:03 -0600)]
fsl-mc: msi: Added FSL-MC-specific member to the msi_desc's union
FSL-MC is a bus type different from PCI and platform, so it needs
its own member in the msi_desc's union.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
J. German Rivera [Wed, 6 Jan 2016 22:03:19 +0000 (16:03 -0600)]
irqdomain: Added domain bus token DOMAIN_BUS_FSL_MC_MSI
Since an FSL-MC bus is a new bus type that is neither PCI nor
PLATFORM, we need a new domain bus token to disambiguate the
IRQ domain for FSL-MC MSIs.
Signed-off-by: J. German Rivera <German.Rivera@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Bhumika Goyal [Mon, 1 Feb 2016 19:31:28 +0000 (01:01 +0530)]
Staging:speakup:add space around '|'
Fix checkpatch.pl check:CHECK: spaces preferred around that '|'.
Add spaces around operands to fix these warnings.
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Geliang Tang [Tue, 15 Dec 2015 15:29:32 +0000 (23:29 +0800)]
staging: wlan-ng: use list_for_each_entry*
Use list_for_each_entry*() instead of list_for_each*() to simplify
the code.
Signed-off-by: Geliang Tang <geliangtang@163.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Bogicevic Sasa [Mon, 14 Dec 2015 14:25:59 +0000 (06:25 -0800)]
drivers:staging:wlan-ng Fix space preferred around that messages
This fixes all "space preferred around that ..." messages from
checkpatch.pl
Signed-off-by: Bogicevic Sasa <brutallesale@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Bogicevic Sasa [Mon, 14 Dec 2015 14:11:18 +0000 (06:11 -0800)]
drivers:staging:wlan-ng Fix all no space necesarry after a cast
This fixes all messages "no space necesarry after a cast" in cfg80211.c
file
Signed-off-by: Bogicevic Sasa <brutallesale@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Gavin O'Leary [Mon, 23 Nov 2015 17:23:36 +0000 (09:23 -0800)]
staging: wlan-ng: Fixed more comments
Fixed more comment issues
Signed-off-by: Gavin O'Leary <gavinoleary3@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Gavin O'Leary [Mon, 23 Nov 2015 17:08:18 +0000 (09:08 -0800)]
staging: wlan-ng: fixed a comment
Fixed a comment style issue.
Signed-off-by: Gavin O'Leary <gavinoleary3@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Christian Colic [Mon, 23 Nov 2015 13:25:05 +0000 (14:25 +0100)]
staging: wlan-ng: (coding style) remove unnecessary blank line before "}"
Fix checkpatch checks: "Blank lines aren't necessary before a close brace '}' "
Remove two unnecessary blank lines.
Signed-off-by: Christian Colic <colic.christian@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Gavin O'Leary [Mon, 9 Nov 2015 06:44:20 +0000 (22:44 -0800)]
Staging: wlan-ng: p80211wep: fixed a block comment style issue
Fixed a comment style issue.
Signed-off-by: Gavin O'Leary <gavinoleary3@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pranjal Bhor [Mon, 18 Jan 2016 19:35:13 +0000 (01:05 +0530)]
staging: wlan-ng: NULL comparisons made elegant
Elegance added for NULL comparisons
Signed-off-by: Pranjal Bhor <bhor.pranjal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pranjal Bhor [Mon, 18 Jan 2016 19:34:56 +0000 (01:04 +0530)]
staging: wlan-ng: Open parenthesis alignment style fix
Alignment of lines matched with open parenthesis
Signed-off-by: Pranjal Bhor <bhor.pranjal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pranjal Bhor [Mon, 18 Jan 2016 19:34:41 +0000 (01:04 +0530)]
staging: wlan-ng: Coding style fix for casting operation
Removed spaces after casting operating
Signed-off-by: Pranjal Bhor <bhor.pranjal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pranjal Bhor [Mon, 18 Jan 2016 19:34:25 +0000 (01:04 +0530)]
staging: wlan-ng: Removed blank lines after braces
Blank lines before closing braces and after opening braces
have been removed.
Signed-off-by: Pranjal Bhor <bhor.pranjal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pranjal Bhor [Mon, 18 Jan 2016 19:34:09 +0000 (01:04 +0530)]
staging: wlan-ng: Logical continuation fixes
Logical continuation coding style issues fixed while
condition checking
Signed-off-by: Pranjal Bhor <bhor.pranjal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pranjal Bhor [Mon, 18 Jan 2016 19:33:49 +0000 (01:03 +0530)]
staging: wlan-ng: Fixed block comments coding style issue
All block comment lines now begin with "*" and end with "*/"
on a new line.
Signed-off-by: Pranjal Bhor <bhor.pranjal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
maomao xu [Thu, 31 Dec 2015 07:20:53 +0000 (15:20 +0800)]
Staging: vt6656: Fixed multiple commenting codig style issues.
Fixed multiple comment blocks that didn't comply with the
kernels coding style.
Signed-off-by: maomao xu <albert008.xu@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Sergey Lysanov [Fri, 18 Dec 2015 08:06:24 +0000 (11:06 +0300)]
drivers:staging:vt6656: Fix coding style issues
This patch fixes the following issues reported by checkpatch.pl:
- code indent should use tabs where possible
Signed-off-by: Sergey Lysanov <lysanovsergey@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Alexey Tulia [Sat, 21 Nov 2015 12:36:47 +0000 (15:36 +0300)]
staging: vt6656: fix definitions of DEVICE_FLAGS_* flags
test_bit and set_bit take the bit number to operate on, rather than a
mask. This patch fixes the DEVICE_FLAGS_* definitions so that they represent
the bit index in priv->flags as opposed to the mask returned by the
BIT macro.
Signed-off-by: Alexey Tulia <alexey.tulia@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:22 +0000 (09:07 +0000)]
staging: vt6655: mac.c replace void __iomem * with struct vnt_private
Moving void __iomem down one level in the following functions
MACbIsRegBitsOn
MACbIsRegBitsOff
MACbIsIntDisable
MACvSetShortRetryLimit
MACvSetLongRetryLimit
MACvGetLongRetryLimit
MACvSetLoopbackMode
MACvSaveContext
MACvRestoreContext
MACbSoftwareReset
MACbSafeSoftwareReset
MACbSafeRxOff
MACbSafeTxOff
MACbSafeStop
MACbShutdown
MACvInitialize
MACvSetCurrRx0DescAddr
MACvSetCurrRx1DescAddr
MACvSetCurrTXDescAddr
MACvSetCurrTx0DescAddrEx
MACvSetCurrAC0DescAddrEx
MACvSetCurrSyncDescAddrEx
MACvSetCurrATIMDescAddrEx
MACvTimer0MicroSDelay
MACvOneShotTimer1MicroSec
MACvSetMISCFifo
MACbPSWakeup
MACvSetKeyEntry
MACvDisableKeyEntry
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:21 +0000 (09:07 +0000)]
staging: vt6655: PSbIsNextTBTTWakeUp Rename bWakeUp wake_up
Removing camel case.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:20 +0000 (09:07 +0000)]
staging: vt6655: rf.c/h Replace DeviceContext with vnt_private
Removing void and including device.h for power.h
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:19 +0000 (09:07 +0000)]
staging: vt6655: power.c replace pDevice with priv
Removing camel case.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:18 +0000 (09:07 +0000)]
staging: vt6655: rf.c rename bResult ret.
Removing camel case and reflecting return value.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:17 +0000 (09:07 +0000)]
staging: vt6655: set_channel replace bResult with ret
Removing camel case.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:16 +0000 (09:07 +0000)]
staging: vt6655: set_channel replace void handler.
Replace with struct vnt_private.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Malcolm Priestley [Sun, 22 Nov 2015 09:07:15 +0000 (09:07 +0000)]
staging: vt6655: channel.c replace pDevice with priv
Removing camel case.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Hari Prasath Gujulan Elango [Wed, 20 Jan 2016 12:52:58 +0000 (12:52 +0000)]
staging: rtl8188eu: use eth_broadcast_addr() in place of memset
Replace the memset of array to broadcast address 0xFF by using the
eth_broadcast_addr() API
Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Geliang Tang [Mon, 1 Feb 2016 14:37:13 +0000 (22:37 +0800)]
staging: rtl8188eu: use list_first_entry_or_null()
Use list_first_entry_or_null() instead of list_empty() + container_of()
to simplify the code.
Signed-off-by: Geliang Tang <geliangtang@163.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Andy Shevchenko [Thu, 10 Dec 2015 15:43:55 +0000 (17:43 +0200)]
staging: rtl8188eu: print OUI with %*ph
There is no need to pass each byte as a parameter when printing values in hex
format. We rather use %*ph specifier for that.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Andy Shevchenko [Thu, 10 Dec 2015 15:43:54 +0000 (17:43 +0200)]
staging: rtl8188eu: replace open-coded print_hex_dump()
No need to reinvent a wheel, i.e. print_hex_dump(). Replace an open-coded
variant by generic kernel helper.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Andy Shevchenko [Thu, 10 Dec 2015 15:43:53 +0000 (17:43 +0200)]
staging: rtl8188eu: provide an absolute path to include folder
Otherwise compiler will complain as follows
CC [M] drivers/staging/rtl8188eu/core/rtw_ap.o
cc1: warning: drivers/staging/rtl8188eu/include: No such file or directory [-Wmissing-include-dirs]
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Chris Elliott [Mon, 7 Dec 2015 22:02:27 +0000 (22:02 +0000)]
Staging: rtl8188eu: core: rtw_debug: fixed a parentheses coding style issue
Removed unnecessary parentheses.
Signed-off-by: Chris Elliott <chris@uksysadmin.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Alexey Tulia [Sat, 21 Nov 2015 10:06:37 +0000 (13:06 +0300)]
staging: rtl8188eu: remove an extra space
drivers/staging/rtl8188eu/core/rtw_wlan_util.c:1377 check_assoc_AP() warn: inconsistent indenting
Signed-off-by: Alexey Tulia <alexey.tulia@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Luca Ceresoli [Wed, 2 Dec 2015 21:54:05 +0000 (22:54 +0100)]
staging: rtl8188eu: rtw_mlme_ext.c: simplify call to issue_action_BA()
Using the ternary operator allows to more concisely write the same
code, and to stay within 80 characters without even increasing the
number of lines.
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Luca Ceresoli [Wed, 2 Dec 2015 21:54:04 +0000 (22:54 +0100)]
staging: rtl8188eu: rename camelcase bAcceptAddbaReq
There is such a field both in struct mlme_ext_info and in struct
registry_priv. Rename both.
Also fix checkpatch issue in the lines touched:
WARNING: line over 80 characters
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Luca Ceresoli [Wed, 2 Dec 2015 21:54:03 +0000 (22:54 +0100)]
staging: rtl8188eu: remove useless variable rtw_AcceptAddbaReq
rtw_AcceptAddbaReq is a static variable, it is set once and never
modified. It is referenced only once, to assign its value to a member
of struct registry_priv with practically the same name.
Get rid of the variable, and move the meaningful part of the comment
near the declaration of the relevant field of struct registry_priv.
Raises a new checkpatch issue, which is fixed in a later commit:
CHECK: Avoid CamelCase: <bAcceptAddbaReq>
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Luca Ceresoli [Wed, 2 Dec 2015 21:54:02 +0000 (22:54 +0100)]
staging: rtl8188eu: rtw_mlme_ext.c: remove commented code
This line is connented since the initial import in commit
7b464c9fa5cc
("staging: r8188eu: Add files for new driver - part 4") and there's no
comment stating how it could ever be useful.
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Luca Ceresoli [Wed, 2 Dec 2015 21:54:01 +0000 (22:54 +0100)]
staging: rtl8188eu: don't cast to void* when calling memset()
The first argument to memset() is (void *), the explicit typecasts are
not needed. They just make code less readable.
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Luca Ceresoli [Wed, 2 Dec 2015 21:54:00 +0000 (22:54 +0100)]
staging: rtl8188eu: add spaces around binary '*'
Fix checkpatch issue:
CHECK: spaces preferred around that '*' (ctx:VxV)
Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Matej Vasek [Mon, 25 Jan 2016 15:02:33 +0000 (16:02 +0100)]
staging: sm750fb, fix typos
The code contained typos like "structur", "fointers", etc. Fix that.
No code change, only comments.
Signed-off-by: Matej Vasek <xvasek1@fi.muni.cz>
Cc: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Cc: Teddy Wang <teddy.wang@siliconmotion.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: <linux-fbdev@vger.kernel.org>
Cc: <devel@driverdev.osuosl.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Bogicevic Sasa [Wed, 25 Nov 2015 21:56:30 +0000 (22:56 +0100)]
drivers:staging:sm750fb Fix all space preferred around messages
This fixes all messages from checkpatch.pl about space preferred
Signed-off-by: Bogicevic Sasa <brutallesale@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Othmar Pasteka [Sun, 8 Nov 2015 10:58:51 +0000 (11:58 +0100)]
staging: sm750fb: fix style for if clause
Fix for checkpatch.pl complaints:
ERROR: that open brace { should be on the previous line
CHECK: spaces preferred around that '+' (ctx:VxV)
Signed-off-by: Othmar Pasteka <pasteka@kabsi.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:31 +0000 (20:04 +0200)]
staging: sm750fb: change definition of POWER_MODE_CTRL multi-bit field
Use more straight-forward definitions for multi-bit field of
POWER_MODE_CTRL register and use open-coded implementation for register
manipulations.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:30 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for POWER_MODE_CTRL single-bit fields
Replace complex definition of POWER_MODE_CTRL register fields with BIT()
macro and use open-coded implementation for register manipulations.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:29 +0000 (20:04 +0200)]
staging: sm750fb: change definition of MODE0_GATE multi-bit fields
Use more straight-forward definitions for multi-bit fields of MODE0_GATE
register.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:28 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for MODE0_GATE single-bit fields
Replace complex definition of MODE0_GATE register fields with BIT() macro
and use open-coded implementation for register manipulations.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:27 +0000 (20:04 +0200)]
staging: sm750fb: change definition of CURRENT_GATE multi-bit fields
Use more straight-forward definitions for multi-bit fields of
CURRENT_GATE register and use open-coded implementation for register
manipulation.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:26 +0000 (20:04 +0200)]
staging: sm750fb: set{Memory, Master}Clock: rename ulReg to reg
Remove HungarianCamelCase notation
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:25 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for CURRENT_GATE single-bit fields
Replace complex definition of CURRENT_GATE register fields with BIT() macro
and use open-coded implementation for register manipulations.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:24 +0000 (20:04 +0200)]
staging: sm750fb: change definition of MISC_CTRL multi-bit fields
Use more straight-forward definitions for multi-bit fields of MISC_CTRL
register and use open-coded implementation for register manipulations.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:23 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for GPIO_MUX single-bit fields
Replace complex definition of GPIO_MUX register fields with BIT() macro
and use open-coded implementation for register manipulations.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:22 +0000 (20:04 +0200)]
staging: sm750fb: ddk750_sii164: fix defines for i2c{Read, Write}reg
For case when USE_HW_I2C is not defined, i2c{Read,Write}reg was wrongly
defined to use old function names.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:21 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for MISC_CTRL single-bit fields
Replace complex definition of MISC_CTRL register fields with BIT() macro
and use open-coded implementation for register manipulations.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:20 +0000 (20:04 +0200)]
staging: sm750fb: ddk750_initHw: rename ulReg to reg
Remove HungarianCamelCase notation
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:19 +0000 (20:04 +0200)]
staging: sm750fb: change definition of SYSTEM_CTRL multi-bit fields
Use more straight-forward definitions for multi-bit fields of
SYSTEM_CTRL register and replace FIELD_GET/SET for these fields with
open-coded implementation.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:18 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for SYSTEM_CTRL single-bit fields
Replace complex definition of SYSTEM_CTRL fields and usage of
FIELD_GET/SET with BIT() macro and open-coded register value modifications
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:17 +0000 (20:04 +0200)]
staging: sm750fb: remove unused DE_STATE2_DE_RESERVED
Definition of reserved fields in a register is not interesting
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:16 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for DE_STATE2 single-bit fields
Replace complex definition of DE_STATE1 fields and usage of FIELD_GET
with BIT() macro and open-coded register value modifications
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:15 +0000 (20:04 +0200)]
staging: sm750fb: use BIT macro for DE_STATE1 single-bit field
Replace complex definition of DE_STATE1 field and usage of FIELD_SET with
BIT() macro and open-coded register value modifications
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 18:04:14 +0000 (20:04 +0200)]
staging: sm750fb: hw_sm750(le)_deWait: rename dwVal to val
Remove HungarianCamelCase notation
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 17:59:55 +0000 (19:59 +0200)]
staging: sm750fb: lynxfb_pci_probe: remove some pr_info
Several pr_info statements in lynxfb_pci_probe seem like debug leftovers
and may be removed.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 17:59:54 +0000 (19:59 +0200)]
staging: sm750fb: introduce sm750fb_frambuffer_alloc
Split framebuffer allocation and registration into a dedicated function
to simplify lynxfb_pci_probe
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 17:59:53 +0000 (19:59 +0200)]
staging: sm750fb: introduce sm750fb_frambuffer_release
Use a function to unregister framebuffer info and release its resources.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 17:59:52 +0000 (19:59 +0200)]
staging: sm750fb: replace dual member of sm750_dev with fb_count
Will be used in futher refactoring of driver _probe and _remove methods.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 17:59:51 +0000 (19:59 +0200)]
staging: sm750fb: lynxfb_pci_remove: remove unused variable
The par variable in lynxfb_pci_remove is only assigned a value and never
used afterwards. Remove it.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 17:59:50 +0000 (19:59 +0200)]
staging: sm750fb: lynxfb_pci_probe: return actual errors
The lynxfb_pci_probe always returned -ENODEV in case of error. Modify it
so that actual error code will be propogated to the caller.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Mike Rapoport [Sun, 17 Jan 2016 17:59:49 +0000 (19:59 +0200)]
staging: sm750fb: disable PCI device if lynxfb_pci_probe fails
In case of error during lynxfb_pci_probe, the function returned without
calling pci_disable_device. Fix it by adding pci_disable_device on the
error cleanup path.
Signed-off-by: Mike Rapoport <mike.rapoport@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ira Weiny [Tue, 22 Dec 2015 02:57:45 +0000 (21:57 -0500)]
staging/rdma/hfi1: Fix Xmit Wait calculation
Total XMIT wait needs to sum the xmit wait values of all the VLs not just
those requested in the query. Also, make the algorithm used for both
PortStatus and PortDataCounters the same.
Reviewed-by: Arthur Kepner <arthur.kepner@intel.com>
Reviewed-by: Breyer, Scott J <scott.j.breyer@intel.com>
Signed-off-by: Ira Weiny <iweiny@gmail.com>
Signed-off-by: Jubin John <jubin.john@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Edward Mascarenhas [Tue, 22 Dec 2015 02:57:44 +0000 (21:57 -0500)]
staging/rdma/hfi1: Clean up comments
Clean up comments by deleting numbering and terms internal to Intel.
The information on the actual bugs is not deleted.
Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Edward Mascarenhas <edward.mascarenhas@intel.com>
Signed-off-by: Jubin John <jubin.john@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Julia Lawall [Wed, 23 Dec 2015 20:42:57 +0000 (21:42 +0100)]
staging: rdma: hfi1: diag: constify hfi1_filter_array structure
The hfi1_filter_array structure is never modified, so declare it as const.
Done with the help of Coccinelle.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Ira Weiny [Tue, 22 Dec 2015 01:31:52 +0000 (20:31 -0500)]
staging/rdma/hfi1: add dd_dev_dbg
To be used in future patches add dd_dev_dbg. dd_* functions properly decode
the hfi1_devdata structure used throughout the driver
Signed-off-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Dean Luick [Tue, 22 Dec 2015 01:31:53 +0000 (20:31 -0500)]
staging/rdma/hfi1: set Gen3 half-swing for integrated devices
Correctly set half-swing for integrated devices. A0 needs all fields set for
CcePcieCtrl. B0 and later only need a few fields set.
Reviewed-by: Stuart Summers <john.s.summers@intel.com>
Signed-off-by: Dean Luick <dean.luick@intel.com>
Signed-off-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Paul Gortmaker [Tue, 17 Nov 2015 00:58:49 +0000 (19:58 -0500)]
staging: drop kbuild workaround dummy module from top dir
This is essentially a revert of
86f69fe9c069dd8608d238581eea259caa1dfc99
("Staging: workaround build system bug"), but to call it a revert would
imply it was wrong -- rather it seems more like it is just no longer
required anymore.
It doesn't list the full details of the failing use case, but the most
obvious would appear to be a "make allnoconfig" that subsequently had set
just CONFIG_STAGING=y in the .config file, to give:
paul@builder:~/git/linux-head$ grep STAGING ../staging-allno/.config
CONFIG_STAGING=y
# CONFIG_STAGING_MEDIA is not set
# CONFIG_STAGING_BOARD is not set
paul@builder:~/git/linux-head$
After building this .config (on ARM, just to be different), we see that
built-in.o is created, and the final vmlinux links OK:
paul@builder:~/git/linux-head$ ls -l ../staging-allno/drivers/staging/built-in.o
-rw-rw-r-- 1 paul paul 257 Nov 16 18:06 ../staging-allno/drivers/staging/built-in.o
paul@builder:~/git/linux-head$ file ../staging-allno/drivers/staging/built-in.o
../staging-allno/drivers/staging/built-in.o: ELF 32-bit LSB relocatable, ARM, version 1, not stripped
paul@builder:~/git/linux-head$ nm ../staging-allno/drivers/staging/built-in.o
nm: ../staging-allno/drivers/staging/built-in.o: no symbols
paul@builder:~/git/linux-head$ ls -l ../staging-allno/vmlinux
-rwxrwxr-x 1 paul paul
1236326 Nov 16 18:07 ../staging-allno/vmlinux
paul@builder:~/git/linux-head$
I also tested an "allmodconfig" and did not see any problems there
either. Switching back to x86-64 and testing several things there didn't
show any issues either. So it appears we do not need to carry the
workaround in tree any longer.
Cc: linux-kbuild@vger.kernel.org
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Acked-by: Michal Marek <mmarek@suse.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pablo G. Gallardo [Thu, 4 Feb 2016 23:43:14 +0000 (21:43 -0200)]
STAGING: COMEDI: Wrap line over 80 characters
This patch wraps lines over 80 characters.
Signed-off-by: Pablo G. Gallardo <pggllrd@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Pablo G. Gallardo [Thu, 4 Feb 2016 23:43:13 +0000 (21:43 -0200)]
STAGING: COMEDI: Remove unnecessary typecast of c90 int constant
This patch removes unnecessary typecast of c90 int constant.
Signed-off-by: Pablo G. Gallardo <pggllrd@gmail.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Spencer E. Olson [Wed, 27 Jan 2016 21:28:29 +0000 (14:28 -0700)]
staging: comedi: ni_mio_common: add finite regeneration to dio output
This patch continues the implementation of reinterpreting stop_arg when
stop_src == TRIG_NONE for national instruments cdio output on e/m-series
devices. This is part of a series of patches that allow a user to have a
specific buffer repeated as-is indefinitely. The contents of the DMA
buffer can be left static or changed by the user via mmap access to the DMA
buffer. If the contents are changed by the user, additional munging is not
performed by the driver and only a single call to
comedi_mark_buffer_written should be done. The original behavior is
preserved when stop_arg == 0, as would be the prior use case.
As opposed to analog output, this patch is relatively simple. First, the
digital output capabilities are much more limited/simple as compared to the
analog output device on NI e/m-series hardware, and second, this patch
relies on changes made with the earlier patch to accomplish limiting the
DMA buffer transfer.
Signed-off-by: Spencer E. Olson <olsonse@umich.edu>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Spencer E. Olson [Wed, 27 Jan 2016 21:28:28 +0000 (14:28 -0700)]
staging: comedi: ni_mio_common: adds finite regeneration to AO output
This patch implements for analog output the reinterpretation of stop_arg
when stop_src == TRIG_NONE to allow the user to specify the length of the
buffer that should be repeated. The intent is to allow a user to have a
specific buffer repeated as-is indefinitely. The contents of the DMA
buffer can be left static or changed by the user via mmap access to the DMA
buffer. If the contents are changed by the user, additional munging is not
performed by the driver and only a single call to
comedi_mark_buffer_written should be done.
Signed-off-by: Spencer E. Olson <olsonse@umich.edu>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Spencer E. Olson [Wed, 27 Jan 2016 21:28:27 +0000 (14:28 -0700)]
staging: comedi: ni_mio_common: Cleans up/clarifies ni_ao_cmd
This patch implements ni_ao_cmd much more closely organized like NI MHDDK
examples and DAQ-STC pseudo-code. Adds comments with some more specific
references to the DAQ-STC.
For stop_src==TRIG_NONE (continuous output mode of entire buffer), the
count for the UC counter was corrected to represent the maximum count
possible (0xffffff). Prior behavior for stop_src=TRIG_NONE did not
actually follow the DAQ-STC. Furthermore, stop_src==TRIG_NONE now
correctly uses code specialized for either m-series or e-series devices.
It should be noted that stop_src==TRIG_NONE does _not_ with this patch
(or with prior behavior in ni_mio_common) actually implement true
continuous output. Rather, the output is simply configured to operate as a
single buffer output, but where the buffer is as large as is possible with
NI-STC hardware.
Signed-off-by: Spencer E. Olson <olsonse@umich.edu>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Spencer E. Olson [Wed, 27 Jan 2016 21:28:26 +0000 (14:28 -0700)]
staging: comedi: ni_mio_common: make more bits in ao_cmd1 reg be stateful
Bits NISTC_AO_CMD1_DAC0_UPDATE_MODE and NISTC_AO_CMD1_DAC1_UPDATE_MODE are
now saved in the local copy of the AO_CMD1 register. This is more
appropriate than prior methods of setting these bits specifically _both_
in the ni_ao_cmd configuration function _and_ the ni_ao_inttrig trigger
function. With this patch, the bits are only specifically called out now
in the ni_ao_cmd configuration function. In the ni_ao_inttrig trigger
function, only the UI_ARM, UC_ARM, BC_ARM bits of the ao_cmd1 register are
specifically called out. Each of these bits is a strobe bit, while the
DAC[0-1]_UPDATE_MODE bits are simple write bits.
Signed-off-by: Spencer E. Olson <olsonse@umich.edu>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Spencer E. Olson [Wed, 27 Jan 2016 21:28:25 +0000 (14:28 -0700)]
staging: comedi: ni_mio_common: Cleans up/clarifies ni_ao_reset
This patch implements ni_ao_reset much more closely organized like NI MHDDK
examples and DAQ-STC pseudo-code. Adds comments with some more specific
references to the DAQ-STC.
Signed-off-by: Spencer E. Olson <olsonse@umich.edu>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Spencer E. Olson [Wed, 27 Jan 2016 21:28:24 +0000 (14:28 -0700)]
staging: comedi: mite: enable continuous regeneration of finite samples
This change enables the mite DMA controller to only transfer the amount of
data needed by a command. By default, the old behavior of transferring the
entire comedi DMA data buffer is still in effect. These changes allow a
command to only transmit a limited portion of that data buffer as needed.
This patch begins to reinterprets stop_arg when stop_src == TRIG_NONE to
allow the user to specify the length of the buffer that should be repeated.
The intent is to allow a user to have a specific buffer repeated as-is
indefinitely. The contents of the DMA buffer can be left static or changed
by the user via mmap access to the DMA buffer. If the contents are changed
by the user, additional munging is not performed by the driver and only a
single call to comedi_mark_buffer_written should be done.
Signed-off-by: Spencer E. Olson <olsonse@umich.edu>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Spencer E. Olson [Tue, 12 Jan 2016 18:05:10 +0000 (11:05 -0700)]
staging: comedi: ni_mio_common: use CR_CHAN more consistently
Generally, the CR_CHAN macro is/should be used to access the relevant bits
for channel identification in cmd->*_arg when the corresponding
cmd->*_src==TRIG_EXT, including cmd->convert_arg in this case.
This patch does not fix a bug per se, as NISTC_AI_MODE1_CONVERT_SRC() already
masks the value sufficiently, but using CR_CHAN() here makes the code clearer as
it avoids passing some irrelevant bits to NISTC_AI_MODE1_CONVERT_SRC() in the
first place.
Signed-off-by: Spencer E. Olson <olsonse@umich.edu>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>