[PATCH v3 3/3] fuse: export pipe_max_size for max_pages

2018-08-14 Thread Constantine Shulyupin
Signed-off-by: Constantine Shulyupin --- fs/pipe.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/pipe.c b/fs/pipe.c index bb0840e234f3..4990d92b0849 100644 --- a/fs/pipe.c +++ b/fs/pipe.c @@ -34,6 +34,7 @@ * be set by root in /proc/sys/fs/pipe-max-size */ unsigned int pipe_max_size

[PATCH v3 1/3] fuse: add max_pages option

2018-08-14 Thread Constantine Shulyupin
fc->max_pages - add mount option max_pages Signed-off-by: Constantine Shulyupin --- fs/fuse/dev.c| 4 ++-- fs/fuse/file.c | 54 fs/fuse/fuse_i.h | 5 - fs/fuse/inode.c | 14 + 4 files changed, 47 insertions(+),

[PATCH] drivers/char/random.c: fix uninitialized value warning

2018-07-18 Thread Constantine Shulyupin
used uninitialized in this function [-Wmaybe-uninitialized] Signed-off-by: Constantine Shulyupin --- drivers/char/random.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/char/random.c b/drivers/char/random.c index 283fe390e878..8e51846d0673 100644 --- a/drivers/char

[PATCH] MAINTAINERS: Add samples/mic/

2018-07-11 Thread Constantine Shulyupin
Signed-off-by: Constantine Shulyupin --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index b40d702337f2..42c439b5cd6a 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -7303,6 +7303,7 @@ F:drivers/misc/mic/ F: drivers/dma/mic_x100_dma.c F

[PATCH] samples: fix compilation of mpssd

2018-07-11 Thread Constantine Shulyupin
declaration of function ‘readv’; Signed-off-by: Constantine Shulyupin --- samples/mic/mpssd/mpssd.c | 5 + 1 file changed, 5 insertions(+) diff --git a/samples/mic/mpssd/mpssd.c b/samples/mic/mpssd/mpssd.c index f42ce551bb48..9cddb9cfdc79 100644 --- a/samples/mic/mpssd/mpssd.c +++ b/samples/mic

[PATCH] scripts/tags.sh: add __ro_after_init

2018-07-11 Thread Constantine Shulyupin
Signed-off-by: Constantine Shulyupin --- scripts/tags.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/tags.sh b/scripts/tags.sh index 66f08bb1cce9..412a70cce558 100755 --- a/scripts/tags.sh +++ b/scripts/tags.sh @@ -245,7 +245,7 @@ exuberant

[PATCH v1] samples: fix compilatin of mpssd

2018-07-07 Thread Constantine Shulyupin
declaration of function ‘readv’; Signed-off-by: Constantine Shulyupin --- samples/mic/mpssd/mpssd.c | 5 + 1 file changed, 5 insertions(+) diff --git a/samples/mic/mpssd/mpssd.c b/samples/mic/mpssd/mpssd.c index f42ce551bb48..9cddb9cfdc79 100644 --- a/samples/mic/mpssd/mpssd.c +++ b/samples/mic

[PATCH v2] fuse: +max_pages

2018-07-04 Thread Constantine Shulyupin
pipe_max_size, which was requested in https://lkml.org/lkml/2012/7/12/32 Changes in v1: https://lkml.org/lkml/2017/8/6/194 - replace FUSE_MAX_PAGES_PER_REQ with FUSE_DEFAULT_MAX_PAGES_PER_REQ and fc->max_pages - add mount option max_pages Signed-off-by: Constantine Shulyu

[PATCH v1] fuse: add configurable max_pages parameter

2017-08-06 Thread Constantine Shulyupin
Replace define FUSE_MAX_PAGES_PER_REQ with the configurable mount parameter max_pages to improve performance. To utilize the max_pages parameter you must also increase the value of bufsize in the user mode library. Signed-off-by: Constantine Shulyupin --- Documentation/filesystems/fuse.txt | 5

[PATCH v9] Documentation: add Device tree bindings for hwmon/nct7802

2015-11-23 Thread Constantine Shulyupin
From: Constantine Shulyupin Introduced subnodes sensor, fan and peci with properties. Signed-off-by: Constantine Shulyupin --- Changed in v9: - Fixed nuvoton,nct7802-sensor - Introduced nuvoton,nct7802-vmon, nuvoton,nct7802-fan-in, nuvoton,nct7802-fan-ctl Changed in v8: - added senor type

Re: [PATCH v8] Documentation: add Device tree bindings for hwmon/nct7802

2015-11-14 Thread Constantine Shulyupin
On Thu, Nov 12, 2015 at 7:26 PM, Rob Herring wrote: > On Mon, Oct 26, 2015 at 10:24:17PM +0200, Constantine Shulyupin wrote: >> From: Constantine Shulyupin >> +Optional subnodes: >> + >> +Sensor subnodes properties: >> + - "compatible", allowed val

[PATCH v3] hwmon: (nct7802) Add device tree support

2015-10-26 Thread Constantine Shulyupin
From: Constantine Shulyupin Introduced nct7802_platform_data, nct7802_parse_dt, nct7802_platform_data_set. Parsing of DT nodes - compatible = "nuvoton,nct7802-sensor", with "sensor-type" = "thermal-diode" | "thermistor" | "voltage"

[PATCH v8] Documentation: add Device tree bindings for hwmon/nct7802

2015-10-26 Thread Constantine Shulyupin
From: Constantine Shulyupin Introduced subnodes sensor, fan and peci with properties. Signed-off-by: Constantine Shulyupin --- Changed in v8: - added senor type "local" - Compatible nodes converted to senor types "vcore", "vcc" Changed in v7: - sensors type (t

[PATCH v7] Documentation: add Device tree bindings for hwmon/nct7802

2015-10-23 Thread Constantine Shulyupin
Introduced subnodes sensor, fan and peci with properties. Signed-off-by: Constantine Shulyupin --- Changed in v7: - sensors type (thermistor, thermistor, voltage) and pwm type selected with type property instead of compatible property. Changed in v6: - Removed previous definition. - Introduced

[PATCH v6] Documentation: add Device tree bindings for hwmon/nct7802

2015-10-02 Thread Constantine Shulyupin
Introduced subnodes sensor, fan and peci with properties. Signed-off-by: Constantine Shulyupin --- Changed in v6: - Removed previous definition. - Introduced subnodes sensor, fan and peci with properties. Changed in v5: - Fixed typos Changed in v4: - Removed registers initialization by names

Re: Please suggest proper format for DT properties.

2015-09-21 Thread Constantine Shulyupin
On Mon, Sep 21, 2015 at 4:51 AM, Rob Herring wrote: > On Fri, Sep 18, 2015 at 5:36 PM, Constantine Shulyupin > wrote: >> Hi, >> >> I am designing DT support for a hwmon chip. >> It has some sensors, each of them can be: >> - "disabled" >>

Please suggest proper format for DT properties.

2015-09-18 Thread Constantine Shulyupin
Hi, I am designing DT support for a hwmon chip. It has some sensors, each of them can be: - "disabled" - "thermal diode" - "thermistor" - "voltage" Four possible options for DT properties format. Option 1: Separated property for each sensor. Example nct7802 node: nct7802 { compati

[PATCH v2] hwmon: (nct7802) hwmon: (nct7802) Add device tree support

2015-09-13 Thread Constantine Shulyupin
Introduced properties sensorX-type with string values "disabled", "thermal diode", "thermistor" and "voltage". Signed-off-by: Constantine Shulyupin --- Changed in v2: - removed tempX_type - introduced nuvoton,sensorX-type with string values Changed in v1

[PATCH v5] Documentation: add Device tree bindings for hwmon/nct7802

2015-09-13 Thread Constantine Shulyupin
https://www.nuvoton.com/hq/products/cloud-computing/hardware-monitors/desktop-server-series/nct7802y/ Changed in v2: - Removed nct7802,reg-init - Added registers initialization by names Introduced in v1: - nct7802,reg-init Signed-off-by: Constantine Shulyupin --- .../devicetree/bindings/hwmon/nc

[PATCH v4] Documentation: add Device tree bindings for hwmon/nct7802

2015-09-08 Thread Constantine Shulyupin
ducts/cloud-computing/hardware-monitors/desktop-server-series/nct7802y/ Changed in v2: - Removed nct7802,reg-init - Added registers initialization by names Introduced in v1: - nct7802,reg-init Signed-off-by: Constantine Shulyupin --- .../devicetree/bindings/hwmon/nct7802.txt

Re: [PATCH v3] Documentation: add Device tree bindings for hwmon/nct7802

2015-09-08 Thread Constantine Shulyupin
> Sure, but why do you need _raw_ register values? > > Why can you not encode this in the DT in a manner that describes what is > connected to this device, then have the kernel figure out any particular > values that need to be poked into registers? > > That'll be easier to read, and it's far more

Re: [PATCH v3] Documentation: add Device tree bindings for hwmon/nct7802

2015-09-08 Thread Constantine Shulyupin
>> Add add Device tree bindings for registers >> which are not covered by hwmon ABI and are required to >> configure specific HW. > > This doesn't really answer my question [1] of why you need these. > > We generally don't encode register values unless there's no other way to > describe the device.

[PATCH v3] Documentation: add Device tree bindings for hwmon/nct7802

2015-09-07 Thread Constantine Shulyupin
/hardware-monitors/desktop-server-series/nct7802y/ Changed in v2: - Removed nct7802,reg-init - Added registers initialization by names Introduced in v1: - nct7802,reg-init Signed-off-by: Constantine Shulyupin --- .../devicetree/bindings/hwmon/nct7802.txt | 28 ++ 1

[PATCH v2] Documentation: add Device tree bindings for hwmon/nct7802

2015-09-06 Thread Constantine Shulyupin
Changed in v2: - Removed nct7802,reg-init - Added registers initialization by names Introduced in v1: - nct7802,reg-init Signed-off-by: Constantine Shulyupin --- --- .../devicetree/bindings/hwmon/nct7802.txt | 24 ++ 1 file changed, 24 insertions(+) create mode

[PATCH v1] Documentation: add Device tree bindings for hwmon/nct7802

2015-08-30 Thread Constantine Shulyupin
reg-init implementation is borowerd from broadcom,c45-reg-init and marvell,reg-init. Signed-off-by: Constantine Shulyupin --- --- .../devicetree/bindings/hwmon/nct7802.txt | 27 ++ 1 file changed, 27 insertions(+) create mode 100644 Documentation/devicetree

[PATCH v1 RESEND] of: Add vendor prefix for Nuvoton

2015-08-05 Thread Constantine Shulyupin
Signed-off-by: Constantine Shulyupin --- Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt b/Documentation/devicetree/bindings/vendor-prefixes.txt index 181b53e..449805a 100644 --- a

[PATCH v1] of: Add vendor prefix for Nuvoton

2015-08-01 Thread Constantine Shulyupin
Signed-off-by: Constantine Shulyupin --- Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/Documentation/devicetree/bindings/vendor-prefixes.txt b/Documentation/devicetree/bindings/vendor-prefixes.txt index 181b53e..449805a 100644 --- a

[PATCH v1] hwmon: (nct7802) Add device tree support

2015-07-31 Thread Constantine Shulyupin
Signed-off-by: Constantine Shulyupin --- The first trial. Question: how to configure local temp4 (EnLTD)? Allow "temp4_type = <3>" (EnLTD=3-2=1) or "temp4_enable = <1>" or else? --- .../devicetree/bindings/hwmon/nct7802.txt | 28 .../devicet

[PATCH v5] hwmon: (nct7802) Add auto_point attributes

2015-07-27 Thread Constantine Shulyupin
Introduced REG_PWM, pwm[1..3]_auto_point[1..5]_temp, pwm[1..3]_auto_point[1..5]_pwm, nct7802_auto_point_attrs, nct7802_auto_point_group, updated nct7802_regmap_is_volatile Signed-off-by: Constantine Shulyupin --- Changed in v5: - removed URL and fixed typo Changed in v4: - fixed expression in

[PATCH v4] hwmon: (nct7802) Add autopoint attributes

2015-07-25 Thread Constantine Shulyupin
Introduced REG_PWM, pwm[1..3]_auto_point[1..5]_temp, pwm[1..3]_auto_point[1..5]_pwm, nct7802_auto_point_attrs, nct7802_auto_point_group, updated nct7802_regmap_is_volatile Signed-off-by: Constantine Shulyupin --- Changed in v4: - fixed expression in nct7802_regmap_is_volatile - added

[PATCH v3] hwmon: (nct7802) Add autopoint attributes

2015-07-25 Thread Constantine Shulyupin
rtFan) registers after enabling autopoint mode. I'll think about validating auto point settings latter. The next fix I would like is to add OF support, which is more important. BTW, Guenter, have you TODO list for the driver? Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct78

[PATCH v2] hwmon: (nct7802) Add autopoint attributes

2015-07-15 Thread Constantine Shulyupin
- introduced pwm[1..3]_auto_point[1..5]_temp and pwm[1..3]_auto_point[1..5]_pwm. - introduced nct7802_auto_point_is_visible - used sysfs_update_group in store_pwm_enable Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 179 +++- 1 file

[PATCH] hwmon: (nct7802) Add autopoint attributes

2015-07-11 Thread Constantine Shulyupin
replaced with pwm[1..3]_auto_point[1..5]_temp and pwm[1..3]_auto_point[1..5]_pwm. - Introduced nct7802_auto_point_is_visible - added used sysfs_update_group in store_pwm_enable Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 179 +++- 1

[PATCH] hwmon: (nct7802) Add autopoint attributes

2015-07-08 Thread Constantine Shulyupin
Introduced PWM_REG, TEMP_REG, auto_pointX_temp, auto_pointX_pwm, nct7802_auto_point_attrs, nct7802_auto_point_group. Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 41 + 1 file changed, 41 insertions(+) diff --git a/drivers/hwmon

[PATCH v2] hwmon: (nct7802) Add pwmX_enable attribute

2015-07-07 Thread Constantine Shulyupin
Introduced REG_SMARTFAN_EN, SMARTFAN_EN_SHIFT, pwmX_enable, show_pwm_enable, store_pwm_enable. Signed-off-by: Constantine Shulyupin --- Change log: Fixed in v2: - Introduced REG_SMARTFAN_EN, SMARTFAN_EN_SHIFT Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 45

[PATCH] hwmon: (nct7802) Add pwmX_enable attribute

2015-07-07 Thread Constantine Shulyupin
Introduced REG_SMARTFAN_EN_BASE, pwmX_enable, show_pwm_enable, store_pwm_enable. Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 46 ++ 1 file changed, 46 insertions(+) diff --git a/drivers/hwmon/nct7802.c b/drivers/hwmon/nct7802.c

[PATCH v4] hwmon: (nct7802) Add pwm control

2015-07-05 Thread Constantine Shulyupin
: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 47 +++ 1 file changed, 47 insertions(+) diff --git a/drivers/hwmon/nct7802.c b/drivers/hwmon/nct7802.c index afa242d..56b6f7b 100644 --- a/drivers/hwmon/nct7802.c +++ b/drivers/hwmon/nct7802.c @@ -102,6

[PATCH] hwmon: (nct7802) Add pwm mode

2015-07-05 Thread Constantine Shulyupin
Introduced: show_pwm_mode, pwm1_mode, pwm2_mode, pwm2_mode Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 26 ++ 1 file changed, 26 insertions(+) diff --git a/drivers/hwmon/nct7802.c b/drivers/hwmon/nct7802.c index 56b6f7b..16e0d17 100644 --- a

[PATCH v2] hwmon: (nct7802) Add pwm mode

2015-07-05 Thread Constantine Shulyupin
Introduced: show_pwm_mode, pwm1_mode, pwm2_mode, pwm2_mode --- Changelog: Fixed in v2: - used SENSOR_DEVICE_ATTR instead of SENSOR_DEVICE_ATTR_2 for pwmX_mode Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 26 ++ 1 file changed, 26 insertions

[PATCH v3] hwmon: (nct7802) Add pwm control

2015-07-05 Thread Constantine Shulyupin
- used kstrtou8 instead kstrtouint Fixed in v3: - spilt functions declarations to fit 80 columns - removed unnecessary initializations - rearranged variable declarations - shortened return expression - renamed store_u8 to store_pwm Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c

[PATCH v2] hwmon: (nct7802) Add pwm control

2015-07-03 Thread Constantine Shulyupin
Notes: Some lines intentionally more than 80 characters because wrapping this lines decreases readability. The patch was checked with scripts/checkpatch.pl --max-line-length=88 Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 47

[PATCH v2] hwmon: (nct7802) Add pwm control

2015-07-03 Thread Constantine Shulyupin
Notes: Some lines intentionally more than 80 characters because wrapping this lines decreases readability. The patch was checked with scripts/checkpatch.pl --max-line-length=88 Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 47

[PATCH] hwmon: (nct7802) Add pwm control

2015-07-03 Thread Constantine Shulyupin
Notes: Some lines intentionally more than 80 characters because wrapping this lines decreases readability. The patch was checked with scripts/checkpatch.pl --max-line-length=88 Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 47

[PATCH] hwmon: (nct7802) Add fan output control

2015-07-02 Thread Constantine Shulyupin
tput Value Location : Index 60h 7.2.92 Fan Control 2 Output Value Location : Index 61h 7.2.93 Fan Control 3 Output Value Location : Index 62h Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 45 + 1 file changed, 45 insertions(+)

[PATCH v3] hwmon: (nct7802) add temperature sensor type attribute

2015-06-30 Thread Constantine Shulyupin
From: const Sensor type: 3 diode (current mode), MD=1 4 thermistor, MD=2 Reference: Nuvoton Hardware Monitoring IC NCT7802Y 7.2.32 Mode Selection Register Location : Index 22h Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 72

[PATCH v2] hwmon: (nct7802) add temperature sensor type attribute

2015-06-29 Thread Constantine Shulyupin
From: const Sensor type: 3 diode (current mode), MD=1 4 thermistor, MD=2 Reference: Nuvoton Hardware Monitoring IC NCT7802Y 7.2.32 Mode Selection Register Location : Index 22h Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 81

[PATCH] hwmon: (nct7802) add temperature sensor type attribute

2015-06-27 Thread Constantine Shulyupin
From: const 0, 3 - Temperature attributes are hidden 1 - Current mode 2 - Thermistor mode Reference: Nuvoton Hardware Monitoring IC NCT7802Y 7.2.32 Mode Selection Register Location : Index 22h Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 53

[PATCH] hwmon: (nct7802) add temperature sensor type attribute

2015-06-27 Thread Constantine Shulyupin
From: const 0, 3 - Temperature attributes are hidden 1 - Current mode 2 - Thermistor mode Reference: Nuvoton Hardware Monitoring IC NCT7802Y 7.2.32 Mode Selection Register Location : Index 22h Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 53

[PATCH] hwmon: (nct7802) fix visibility of temp3

2015-06-26 Thread Constantine Shulyupin
From: const Excerpt from datasheet: 7.2.32 Mode Selection Register RTD3_MD : 00=Closed , 01=Reserved , 10=Thermistor mode , 11=Voltage sense Show temp3 only in Thermistor mode Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCH] fix nct7802_temp_is_visible

2015-06-24 Thread Constantine Shulyupin
From: const Fixed registers are invisible only when registers' mode is 0 Signed-off-by: Constantine Shulyupin --- drivers/hwmon/nct7802.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/hwmon/nct7802.c b/drivers/hwmon/nct7802.c index ec56782..65e40c2 1

Re: [PATCH v4] checkpatch: debugfs_remove() can take NULL

2012-11-20 Thread Constantine Shulyupin
On Tue, Nov 20, 2012 at 4:58 PM, Joe Perches wrote: > I don't think it's an issue. I'm not sure anyone > really uses --ignore for much other than LONG_LINE. Indeed. Must all code be 80 characters width? My be my be better to make line length configurable than ignore it? Or at least print actual

Re: [PATCH v4] checkpatch: debugfs_remove() can take NULL

2012-11-20 Thread Constantine Shulyupin
>> On Tue, 2012-11-20 at 14:29 +, Andy Whitcroft wrote: >> Perhaps just >> WARN("NEEDLESS_IF", > > I would cirtainly be happy with that, I was trying to avoid changing the > capacity for the existing NEEDLESS_KFREE. If compatibility there isn't > an issue then tha

[PATCH v4] checkpatch: debugfs_remove() can take NULL

2012-11-17 Thread Constantine Shulyupin
From: Constantine Shulyupin debugfs_remove() and debugfs_remove_recursive() can take a NULL, so let's check and warn about that. Changes since v3, as Joe Perches suggested: - removed redundant check Changes since v2, as Joe Perches suggested: - match whitespace around argument Changes

[PATCH v3] checkpatch: debugfs_remove() can take NULL

2012-11-17 Thread Constantine Shulyupin
From: Constantine Shulyupin debugfs_remove() and debugfs_remove_recursive() can take a NULL, so let's check and warn about that. Changes since v2, as Joe Perches suggested: - match whitespace around argument Changes since v1, as Joe Perches suggested: - added debugfs_remove_recursive

[PATCH v2] checkpatch: debugfs_remove() can take NULL

2012-11-17 Thread Constantine Shulyupin
From: Constantine Shulyupin debugfs_remove() and debugfs_remove_recursive() can take a NULL, so let's check and warn about that. Channegs since v1: - added debugfs_remove_recursive - all tests for pattenrs are "if (a) xxx(a)" are consolidates Signed-off-by: Consta

[no subject]

2012-11-17 Thread Constantine Shulyupin
>From 21f1095ce30b21f1729c64eb26b7921bbb3bcc8d Mon Sep 17 00:00:00 2001 From: Constantine Shulyupin Date: Sat, 17 Nov 2012 14:27:18 +0200 Subject: [PATCH v2] checkpatch: debugfs_remove() can take NULL debugfs_remove() and debugfs_remove_recursive() can take a NULL, so let's check

Re: [PATCH v2] LDT - Linux Driver Template

2012-11-17 Thread Constantine Shulyupin
On Fri, Nov 16, 2012 at 12:40 AM, Greg KH wrote: > On Thu, Nov 15, 2012 at 09:22:17PM +0200, Constantine Shulyupin wrote: >> From: Constantine Shulyupin >> >> LDT is useful for Linux driver development beginners, >> hackers and as starting point for a new drivers. &g

[PATCH] checkpatch: debugfs_remove() can take NULL

2012-11-17 Thread Constantine Shulyupin
From: Constantine Shulyupin debugfs_remove() can take a NULL, so let's check and warn about that. Signed-off-by: Constantine Shulyupin --- scripts/checkpatch.pl |8 1 file changed, 8 insertions(+) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index f18750e..c0

Re: [PATCH v2] LDT - Linux Driver Template

2012-11-16 Thread Constantine Shulyupin
On Fri, Nov 16, 2012 at 11:46 AM, Bjørn Mork wrote: > Greg KH writes: > >> Normally you just start with a >> driver for a device like the one you need to write and modify it from >> there. > > Yes. > > Even if the template driver is fixed up to be the most beautiful driver > ever made, it will s

Re: [PATCH] LDT - Linux Driver Template

2012-11-14 Thread Constantine Shulyupin
On Wed, Nov 14, 2012 at 5:42 AM, Ryan Mallon wrote: > On 14/11/12 05:46, Constantine Shulyupin wrote: >> From: Constantine Shulyupin >> + if (kfifo_is_empty(&in_fifo)) { > > Doesn't this require locking against whatever is filling the fifo? I seems doesn'

Re: [PATCH] LDT - Linux Driver Template

2012-11-13 Thread Constantine Shulyupin
On Tue, Nov 13, 2012 at 9:01 PM, Greg KH wrote: >> +#define pr_debug_hex(h) pr_debug("%s:%d %s %s = 0x%lX\n", \ >> + __file__, __LINE__, __func__, #h, (long int)h) > > This is not needed at all, just use the proper printk() attribute. Macro above allows tidy tracing code: pr_deb

Re: [PATCH] LDT - Linux Driver Template

2012-11-13 Thread Constantine Shulyupin
> Now I agree using the char interface isn't the most "obvious" and I have > a set of ideas/half-baked patches floating around that aim to clean it > up, but for now, I'd recommend just using the misc interface, it's > worlds simpler, makes sense, and handles all of the struct device work > for you

Re: [PATCH] LDT - Linux Driver Template

2012-11-13 Thread Constantine Shulyupin
On Wed, Nov 14, 2012 at 1:02 AM, Greg KH wrote: > On Wed, Nov 14, 2012 at 12:31:13AM +0200, Constantine Shulyupin wrote: >> >> + * Device Model (class, device) >> > Don't use class code in an example, it is slowly going away from the >> > whole kernel. &

Re: [PATCH] LDT - Linux Driver Template

2012-11-13 Thread Constantine Shulyupin
>> + * Device Model (class, device) > Don't use class code in an example, it is slowly going away from the > whole kernel. What to use instead class_create and device_create? Thank you. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord.

[PATCH] LDT - Linux Driver Template

2012-11-13 Thread Constantine Shulyupin
From: Constantine Shulyupin LDT is useful for Linux driver development beginners, hackers and as starting point for a new drivers. The driver uses following Linux facilities: module, platform driver, file operations (read/write, mmap, ioctl, blocking and nonblocking mode, polling), kfifo

[PATCH] Add FDT support to Pandaboard initialization

2012-10-27 Thread Constantine Shulyupin
From: Constantine Shulyupin Problem: - FDT is supported only by generic OMAP board initialization in arch/arm/mach-omap2/board-generic.c and lacks some configurations, which are not yet configured in FDT (USB for example). Solution: - arch/arm/mach-omap2/board-omap4panda.c supports

[RESEND PATCH v3] USB: usb-skeleton.c: fix compilation error and restored kref_put on fail in skel_open

2012-10-22 Thread Constantine Shulyupin
From: Constantine Shulyupin Fixing compilaton error. Incrementing usage counter only on successful execution of skel_open. Removing redundant locking Some last changes in function skel_open and finally commit 52a7499 Revert "USB: usb-skeleton.c: fix open/disconnect race" introduce

[PATCH] rename ccg init and exit functions to conventional names

2012-10-15 Thread Constantine Shulyupin
From: Constantine Shulyupin Previous names of init and exit functions "init" and "cleanup" are unconventional and are not friendly for source navigation with tags. New names "ccg_init" and "ccg_exit" are conveninal and source navigation friendl

[PATCH v7] Initialize USB on dm365 EVM

2012-10-11 Thread Constantine Shulyupin
From: Constantine Shulyupin Call USB initialization davinci_setup_usb from board initialization dm365_evm_init. Tested with OTG configuration, usb gadget g_zero on DM365 EVM connected to PC. Note: register USB_PHY_CTRL must have flag USBPHY_CLKFREQ_24MHZ References: Original patch by

[PATCH v7] Enable USB peripheral mode on dm365 EVM

2012-10-11 Thread Constantine Shulyupin
From: Constantine Shulyupin Sets USB PHY clock source to 24 MHz clock. Tested with OTG configuration, usb gadget g_zero on DM365 EVM connected to PC. To active the patch need to call davinci_setup_usb from dm365_evm_init References: Definition of USB_PHY_CTRL and PHYCLKFREQ: - http

Re: [PATCH] usb: remove CONFIG_USB_MUSB_HOST etc

2012-10-11 Thread Constantine Shulyupin
n Mon, Oct 08, 2012 at 18:47:07, Constantine Shulyupin wrote: >>>> From: Constantine Shulyupin >>>> >>>> Remove USB configuration in arch/arm/mach-davinci/usb.c accordingly >>>> CONFIG_USB_MUSB_OTG CONFIG_USB_MUSB_PERIPHERAL CONFIG_USB_MUSB_HOST >>>

Re: [PATCH v6] Enable USB peripheral mode on dm365 EVM

2012-10-10 Thread Constantine Shulyupin
configurations from board files anyway. >From http://www.spinics.net/lists/kernel/msg1414914.html On Wed, Oct 10, 2012 at 9:27 PM, Sergei Shtylyov wrote: > Hello. > > > On 10-10-2012 14:33, Constantine Shulyupin wrote: > >> From: Constantine Shulyupin >> >> Sets

[PATCH v3] USB: usb-skeleton.c: fix compilation error and restored kref_put on fail in skel_open

2012-10-10 Thread Constantine Shulyupin
From: Constantine Shulyupin Fixing compilaton error. Incrementing usage counter only on successful execution of skel_open. Removing redundant locking Some last changes in function skel_open and finally commit 52a7499 Revert "USB: usb-skeleton.c: fix open/disconnect race" introduce

[PATCH v6] Enable USB peripheral mode on dm365 EVM

2012-10-10 Thread Constantine Shulyupin
From: Constantine Shulyupin Sets USB PHY clock source to 24 MHz clock and call USB configuration from board initialization. Tested with OTG configuration, usb gadget g_zero on DM365 EVM connected to PC. References: Definition of USB_PHY_CTRL and PHYCLKFREQ: - http://www.makelinux.com/lib/ti

[PATCH v2] USB: usb-skeleton.c: fix compilation error and restore kref_put on fail in skel_open

2012-10-10 Thread Constantine Shulyupin
From: Constantine Shulyupin Function skel_open increments usage count for the device with kref_get and the usage count should be decremented on the function failure. Some last changes in function skel_open and finally commit 52a7499 Revert "USB: usb-skeleton.c: fix open/disconnect

[PATCH] usb: remove CONFIG_USB_MUSB_HOST etc

2012-10-08 Thread Constantine Shulyupin
From: Constantine Shulyupin Remove USB configuration in arch/arm/mach-davinci/usb.c accordingly CONFIG_USB_MUSB_OTG CONFIG_USB_MUSB_PERIPHERAL CONFIG_USB_MUSB_HOST and set MUSB_OTG configuration by default because this configuration options are removed from Kconfig. Signed-off-by: Constantine

[PATCH] USB: usb-skeleton.c: fix compilation error and restore kref_put on fail in skel_open

2012-10-07 Thread Constantine Shulyupin
From: Constantine Shulyupin Function skel_open increments usage count for the device with kref_get and the usage count should be decremented on the function failure. Some last changes in function skel_open and finally commit 52a7499 Revert "USB: usb-skeleton.c: fix open/disconnect

[PATCH v5] Enable USB peripheral mode on dm365 EVM

2012-10-04 Thread Constantine Shulyupin
From: Constantine Shulyupin Defines OTG as default USB mode because defines CONFIG_USB_MUSB_HOST, CONFIG_USB_MUSB_PERIPHERAL, CONFIG_USB_MUSB_OTG are not used in kernel configuration. Sets USB PHY clock source to 24 MHz clock and call USB configuration from board initialization. Tested with

[PATCH v4] Enable USB peripheral on dm365 EVM

2012-10-04 Thread Constantine Shulyupin
From: Constantine Shulyupin Signed-off-by: Constantine Shulyupin --- Note: USBPHY_CTL_PADDR and USBPHY_CLKFREQ_24MHZ are defined in board-dm365-evm.c because davinci.h can't be included from drivers/usb/musb/. May be davinci.h should be renamed and moved to arch/arm/mach-davinci/in