Commit graph

94 commits

Author SHA1 Message Date
Ksenija Stanojevic
305b37bd01 misc: Move panel driver out of staging
Move panel driver from drivers/staging/panel to drivers/misc.

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-03 14:14:22 -08:00
Greg Kroah-Hartman
4cff7adbeb Merge 4.5-rc2 into staging-next
This fixes a merge issue with the panel driver, and picks up fixes in
iio and other drivers that we want here.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-02-01 12:50:26 -08:00
Sudip Mukherjee
b64a1cbef6 Revert "Staging: panel: usleep_range is preferred over udelay"
This reverts commit ebd43516d3.

We should not be sleeping inside spin_lock.

Fixes: ebd43516d3 ("Staging: panel: usleep_range is preferred over udelay")
Cc: Sirnam Swetha <theonly.ultimate@gmail.com>
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Reported-by: Huang, Ying <ying.huang@intel.com>
Tested-by: Huang, Ying <ying.huang@intel.com>
Cc: stable <stable@vger.kernel.org> # 4.4
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:26:18 -08:00
Ksenija Stanojevic
8aa7307b78 Staging: panel: Make code more readable
Repace 'for' statement by strchr() function to make code more readable.

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:23:38 -08:00
Ksenija Stanojevic
52ebf93f36 Staging: panel: Reduce value range for *name
out is 0-9 so it's too much for om, therefore reduce value range for
*name from '0'-'9' to '0'-'7'.

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:23:38 -08:00
Ksenija Stanojevic
d12f27e8b2 Staging: panel: Remove ULL
Remove ULL on om and im, since it's useless.

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:23:38 -08:00
Ksenija Stanojevic
35fe087284 Staging: panel: Remove typedef pmask_t
Use __u64 instead of pmask_t and remove pmask_t since is useless.

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:23:38 -08:00
Ksenija Stanojevic
d938e1eb2f Staging: panel: Use u8 type
Declare om, im, omask and imask as u8 to remove any confusion if
that describes the 8 bits of the data bus on the parallel port.
Also change return type of lcd_write_data() to u8.

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:23:38 -08:00
Ksenija Stanojevic
7a725972e2 Staging: panel: Remove space
No space is necessary after a cast, therefore remove it.
Found by checkpatch.pl

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:22:01 -08:00
Ricardo Ruedas
df44f1504b staging: panel: remove warnings line over 80 characters
This patch removes the warnings reported by checkpatch.pl
for line over 80 characters.

Signed-off-by: Ricardo Ruedas <ricardo.ruedas@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:10:22 -08:00
Daniel H. Hemmingsen
76e9521fc9 Staging: panel: Fixed a spacing after cast coding style issue
Fixed a spacing after cast coding style issue.

Signed-off-by: Daniel H. Hemmingsen <dhh.kernel@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-28 22:10:22 -08:00
Sirnam Swetha
832bf28ce4 Staging: panel: Logical continuations should be on the previous line
This patch fixes the checkpatch issue:

CHECK: Logical continuations should be on the previous line

Signed-off-by: Sirnam Swetha <theonly.ultimate@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-29 07:55:17 +09:00
Sirnam Swetha
ebd43516d3 Staging: panel: usleep_range is preferred over udelay
This patch fixes the issue:

CHECK: usleep_range is preferred over udelay; see
Documentation/timers/timers-howto.txt

Signed-off-by: Sirnam Swetha <theonly.ultimate@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-29 07:55:17 +09:00
Sirnam Swetha
46f566ed53 Staging: panel: Removing multiple blank lines
This patch fixes the checkpatch issue

CHECK: Please don't use multiple blank lines

Signed-off-by: Sirnam Swetha <theonly.ultimate@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-29 07:55:17 +09:00
Sirnam Swetha
2b3c9eb292 Staging: panel: spaces preferred around that '/'
This patch fixes the checkpatch issue:

CHECK: spaces preferred around that '/'

Signed-off-by: Sirnam Swetha <theonly.ultimate@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-29 07:55:17 +09:00
Amitoj Kaur Chawla
79f2af620e staging: panel: Prefer using BIT Macro
Replace bit shifting on 1 with the BIT(x) Macro

The semantic patch used to find this is:
@@ int g; @@

-(1 << g)
+BIT(g)

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-16 23:05:17 -07:00
Aybuke Ozdemir
b565b3fbec Staging: panel: Replace NULL comparison.
Use ! operating instead of NULL checks.
Addresses "CHECK: Comparison to NULL" from checkpatch.pl.

Signed-off-by: Aybuke Ozdemir <aybuke.147@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-10-04 09:37:23 +01:00
Nayeemahmed Badebade
8c17893c2f staging: panel: panel.c: Fixed coding style issues
Fixed warnings reported by checkpatch.pl:
 - Block comments use a trailing */ on a separate line
 - Block comments use * on subsequent lines

Signed-off-by: Nayeemahmed Badebade <itachi.opsrc@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:37 -07:00
Alex Wilson
881bf28123 staging: panel: fix block comment usage
Fixed two coding style warnings concerning multiline comments.

Signed-off-by: Alex Wilson <alex.david.wilson@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-07-31 16:18:43 -07:00
Linus Torvalds
23908db413 Staging driver patches for 4.2-rc1
Here's the big, really big, staging tree patches for 4.2-rc1.
 
 Loads of stuff in here, almost all just coding style fixes / churn, and
 a few new drivers as well, one of which I just disabled from the build a
 few minutes ago due to way too many build warnings.
 
 Other than the one "disable this driver" patch, all of these have been
 in linux-next for quite a while with no reported issues.
 
 Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2
 
 iEYEABECAAYFAlWNpc0ACgkQMUfUDdst+ym8EgCg0pL1Qcf9Se3jAc96fLt+itpv
 Rd0AoI9uJcq8Qm7d+IXnz3ojLnN9xvN3
 =xt0u
 -----END PGP SIGNATURE-----

Merge tag 'staging-4.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging

Pull staging driver updates from Greg KH:
 "Here's the big, really big, staging tree patches for 4.2-rc1.

  Loads of stuff in here, almost all just coding style fixes / churn,
  and a few new drivers as well, one of which I just disabled from the
  build a few minutes ago due to way too many build warnings.

  Other than the one "disable this driver" patch, all of these have been
  in linux-next for quite a while with no reported issues"

* tag 'staging-4.2-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (1163 commits)
  staging: wilc1000: disable driver due to build warnings
  Staging: rts5208: fix CHANGE_LINK_STATE value
  Staging: sm750fb: ddk750_swi2c.c: Insert spaces before parenthesis
  Staging: sm750fb: ddk750_swi2c.c: Place braces on correct lines
  Staging: sm750fb: ddk750_swi2c.c: Insert spaces around operators
  Staging: sm750fb: ddk750_swi2c.c: Replace spaces with tabs
  Staging: sm750fb: ddk750_swi2c.h: Shorten lines to under 80 characters
  Staging: sm750fb: ddk750_swi2c.h: Replace spaces with tabs
  Staging: sm750fb: modedb.h: Shorten lines to under 80 characters
  Staging: sm750fb: modedb.h: Replace spaces with tabs
  staging: comedi: addi_apci_3120: rename 'this_board' variables
  staging: comedi: addi_apci_1516: rename 'this_board' variables
  staging: comedi: ni_atmio: cleanup ni_getboardtype()
  staging: comedi: vmk80xx: sanity check context used to get the boardinfo
  staging: comedi: vmk80xx: rename 'boardinfo' variables
  staging: comedi: dt3000: rename 'this_board' variables
  staging: comedi: adv_pci_dio: rename 'this_board' variables
  staging: comedi: cb_pcidas64: rename 'thisboard' variables
  staging: comedi: cb_pcidas: rename 'thisboard' variables
  staging: comedi: me4000: rename 'thisboard' variables
  ...
2015-06-26 15:46:08 -07:00
Sudip Mukherjee
9be83c0a44 staging: panel: use new parport device model
Converted to use the new device-model parallel port.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01 07:08:19 +09:00
Nicholas Mc Guire
895875a3d8 staging: panel: use schedule_timeout_interruptible()
API consolidation with coccinelle found:
./drivers/staging/panel/panel.c:782:2-18:
        consolidation with schedule_timeout_*() recommended

This is a 1:1 conversion with respect to schedule_timeout() to the
schedule_timeout_interruptible() helper only - so only an API
consolidation to improve readability. The timeout was being passed
as (ms * HZ + 999) / 1000 but that simply looks wrong - rather than
"manual" converting to jiffies, msecs_to_jiffies which handles all
corner-cases correctly, was used.

Patch was compile tested with x86_64_defconfig + CONFIG_STAGING=y,
CONFIG_PARPORT=m, CONFIG_PANEL=m

Signed-off-by: Nicholas Mc Guire <hofrat@osadl.org>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-31 12:04:36 +09:00
Sudip Mukherjee
7d98c63edc staging: panel: fix stackdump
if we load the module, unload and then again try to load the module, we
will get a stackdump. In the module_exit function we are unregistering
the device and releasing the parport. So when we reach the detach
function parport is already null and the unregister_reboot_notifier()
is never called. When we again try to load the module it again tries
register_reboot_notifier() and gives us a stackdump as its earlier
registration is still not removed. It was caused by the
commit bb046fef96 ('staging: panel: register reboot')
Fix this by moving all the unregistering and releasing in the detach
function, which should be the ideal case as the detach will be called if
we try to unregister the driver or if the parport is removed.

Fixes: bb046fef96 ('staging: panel: register reboot')
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-05-24 13:35:25 -07:00
Sudip Mukherjee
9059c615a8 staging: panel: remove duplicate code
both the misc_deregister(), parport_release() and
parport_unregister_device() is there in the module_exit function also.
detach is called from parport_unregister_driver() and by the time
detach executes misc_deregister(), parport_release() and
parport_unregister_device() has already executed marking
keypad_initialized and lcd.initialized  as false. so this part of the
code will never execute.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-04-30 17:10:51 +02:00
Sudip Mukherjee
2c20d92dad staging: panel: fix lcd type
the lcd type as defined in the Kconfig is not matching in the code.
as a result the rs, rw and en pins were getting interchanged.
Kconfig defines the value of PANEL_LCD to be 1 if we select custom
configuration but in the code LCD_TYPE_CUSTOM is defined as 5.

my hardware is LCD_TYPE_CUSTOM, but the pins were assigned to it
as pins of LCD_TYPE_OLD, and it was not working.
Now values are corrected with referenece to the values defined in
Kconfig and it is working.
checked on JHD204A lcd with LCD_TYPE_CUSTOM configuration.

Cc: <stable@vger.kernel.org> # 2.6.32+
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-26 11:00:22 +01:00
Sudip Mukherjee
dec8c37818 staging: panel: remove initialization check
no need to monitor init_in_progress now as keypad_send_key() can only
be called after the timer is initialized. and timer is initialized
from keypad_init() which is in the attach section and can only execute
after the module has initialized.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20 14:06:12 +01:00
Sudip Mukherjee
e134201b7a staging: panel: return register value
we were returning success even if the module failed to register.
now we are returning the actual return value, success or error.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20 14:06:12 +01:00
Sudip Mukherjee
bb046fef96 staging: panel: register reboot
we donot need the reboot notifier in module init section, as the
notifier is used after lcd is initialized. so lets register for the
reboot notifier only after we have successfully attached to the
parallel port. and similarly unregister at detach.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20 14:06:12 +01:00
Sudip Mukherjee
733345ec4e staging: panel: initialize lcd if lcd enabled
initialiaze lcd parameters only if lcd is enabled.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06 16:31:58 -08:00
Sudip Mukherjee
f43de77c9d staging: panel: register driver after checking device
register the driver only if lcd or keypad has been enabled and if
both are disabled then just exit.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-06 16:31:57 -08:00
Aya Mahfouz
8f6e36c55a staging: panel: replace init_timer by setup_timer
This patch replaces init_timer and the 2 step initialization of function
and data by setup_timer to make the code more concise.

The issue was discovered using the following coccinelle script:

@@
expression ds, e1, e2;
@@

-init_timer (&ds);
+setup_timer (&ds, e1, e2);
...
(
-ds.function = e1;
...
-ds.data = e2;
|
-ds.data = e2;
...
-ds.function = e1;
)

Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-02-26 13:12:40 -08:00
Davidlohr Bueso
2be90fef97 drivers/staging: use current->state helpers
Call __set_current_state() instead of assigning the new state directly.
These interfaces also aid CONFIG_DEBUG_ATOMIC_SLEEP environments,
keeping track of who changed the state.

Signed-off-by: Davidlohr Bueso <dbueso@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-28 11:25:28 -08:00
Mariusz Gorski
2114924a9e staging: panel: Remove magic numbers in LCD commands
Get rid of magic numbers in LCD commands and replace them with defined
values, so that it's more obvious that the commands are doing.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-12 06:39:33 -08:00
Mariusz Gorski
1216ed713b staging: panel: Remove unused variable
Remove lcd.left_shift because it is only written to at some places but
never read from.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-01-12 06:39:33 -08:00
Mariusz Gorski
6d8b588c32 staging: panel: Move LCD-related state into struct lcd
Move more or less all LCD-related state into struct lcd
in order to get better cohesion; use bool instead of int
where it makes sense.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:35 -08:00
Mariusz Gorski
1a4b2e3e6c staging: panel: Remove more magic number comparison
Use a defined value instead of magic number comparison
for checking whether a module param value has been set.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:35 -08:00
Mariusz Gorski
8037e2a3c0 staging: panel: Refactor LCD init code
Rework lcd_init method to make it a little bit more clear about
the precedence of the params, move LCD geometry and pins layout
to the LCD struct and thus make the LCD-related module params
effectively read-only.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:34 -08:00
Mariusz Gorski
87b8e0c881 staging: panel: Make two more module params read-only
Make keypad_type and lcd_type module params read-only.
This step also starts making it more clear what is
the precedence of device params coming from different
sources (device profile, runtime module param values etc).

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:34 -08:00
Mariusz Gorski
a8b2580b73 staging: panel: Start making module params read-only
Start decoupling module params from the actual device state,
both for lcd and keypad, by keeping the params read-only
and moving the device state to related structs.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:34 -08:00
Mariusz Gorski
2d35bcf66c staging: panel: Use defined value or checking module params state
Avoid magic number and use a comparison with a defined value instead
that checks whether module param has been set by the user to some
value at loading time.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:34 -08:00
Mariusz Gorski
36277d4ad0 staging: panel: Remove magic numbers
Get rid of magic numbers indicating that the value of a module param
is not set. Use a defined value instead.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:34 -08:00
Mariusz Gorski
d9114767d1 staging: panel: Call init function directly
Remove useless function and let the kernel call the actual
init function directly.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:34 -08:00
Mariusz Gorski
59a66a24e2 staging: panel: Set default parport module param value
Set default parport module param value to DEFAULT_PARPORT so that
a if-block can be avoided.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-by: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-12-02 16:34:34 -08:00
Mariusz Gorski
98fac3d3db staging: panel: Use better names for two defined values
Give DEFAULT_KEYPAD and DEFAULT_LCD defines better names,
so that their meaning is emphasized.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-By: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26 13:53:25 -08:00
Mariusz Gorski
98e0e762ea staging: panel: Reorder module parameter declarations
Change the order of the module parameter declarations
so that it matches the Kconfig order.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-By: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26 13:53:25 -08:00
Mariusz Gorski
1e13e8aa1f staging: panel: Reorder DEFAULT_* values redefines
Change the order of the DEFAULT_* values redefines so that it
matches the Kconfig order.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-By: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26 13:53:25 -08:00
Mariusz Gorski
fe4d7e2cc9 staging: panel: Reorder initial DEFAULT_* defines
Change the order of the initial DEFAULT_* defines so that it
matches the Kconfig order.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Acked-By: Willy Tarreau <w@1wt.eu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-26 13:53:25 -08:00
Mariusz Gorski
f4757af851 staging: panel: Fix single-open policy race condition
Fix the implementation of a single-open policy for both
devices (lcd and keypad) by using atomic_t instead of plain ints.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-11-05 14:58:07 -08:00
Mariusz Gorski
6c3773defb staging: panel: Use designated initializers
Fix "warning: missing initializer [-Wmissing-field-initializers]"
by using designated struct initializers.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-10-29 16:28:17 -07:00
Vincent Heuken
083b3638d3 Staging: panel: fixed frivilous else statement warning
Fixed one instance of the following checkpatch.pl warning in
panel.c:
WARNING: else is not generally useful after a break or return

Signed-off-by: Vincent Heuken <me@vincentheuken.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-07-10 15:12:51 -07:00