Re: [PATCH v15 1/3] drm: rockchip: Add basic drm driver

2016-03-14 Thread Mark yao

On 2016年03月14日 21:35, Tomeu Vizoso wrote:

On 2 December 2014 at 10:15, Mark Yao  wrote:

diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_vop.c 
b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
new file mode 100644
index 000..e7ca25b
--- /dev/null
+++ b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
@@ -0,0 +1,1455 @@

...

+static bool vop_crtc_mode_fixup(struct drm_crtc *crtc,
+   const struct drm_display_mode *mode,
+   struct drm_display_mode *adjusted_mode)
+{
+   if (adjusted_mode->htotal == 0 || adjusted_mode->vtotal == 0)
+   return false;

Hi Mark,

what's the rationale for this?

Disabling a CRTC as in [0] will cause mode_fixup() to be called with
an empty mode, failing that test.

Removing the check seems to get things working fine for a short while,
but a later modeset invariably gets the VOP to hang (as reported by
[1]).

Do you know why that check was put in place and what exactly could be
causing the hw to hang?

[0] 
https://cgit.freedesktop.org/xorg/app/intel-gpu-tools/tree/lib/igt_kms.c#n1616
[1] 
https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/drivers/gpu/drm/rockchip/rockchip_drm_vop.c#n873

Thanks,

Tomeu


Hi Tomeu

Just thinking that "adjusted_mode->htotal == 0 || adjusted_mode->vtotal 
== 0" is not a good mode for vop.


And you said VOP hang, only WARN_ON error message? or system hang, die?

I think maybe crtc disable too fast, vblank is off, then no one can feed the 
wait_update_complete.
Can you test it again with following patch?
drivers/gpu/drm/rockchip/rockchip_drm_vop.c
@@ -503,6 +503,8 @@ static void vop_crtc_disable(struct drm_crtc *crtc)
if (!vop->is_enabled)
return;
 
+   vop_crtc_wait_for_update(crtc);

+
drm_crtc_vblank_off(crtc);

Thanks.

--
Mark Yao


--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2 0/5] Add Korean translation of memory-barriers.txt

2016-03-14 Thread Paul E. McKenney
On Tue, Mar 15, 2016 at 08:36:05AM +0900, Minchan Kim wrote:
> On Tue, Mar 15, 2016 at 06:52:11AM +0900, SeongJae Park wrote:
> > On Tue, Mar 15, 2016 at 5:17 AM, Paul E. McKenney
> >  wrote:
> > > On Fri, Mar 11, 2016 at 12:06:55AM +0900, SeongJae Park wrote:
> > >> This patchset aims to add Korean translation of memory-barriers document.
> > >>
> > >> The patchset starts from fixing minor and trivial problems in the 
> > >> original
> > >> document that found during translation.  After that, the final patch 
> > >> adds the
> > >> Korean translation of the document.
> > >>
> > >> The patches are based on recent next tree:
> > >> 0f6dd067b9c3c712b1177fa2fc0deb21805c771c ("Add linux-next specific files 
> > >> for
> > >> 20160309")
> > >
> > > Queued, thank you!  I am going to have to trust you on the Korean, good
> > > thing you list yourself as maintainer.  ;-)
> > 
> > Thank you, Paul!  I believe this change may help future Korean hackers.  
> > Also,
> > I will do my best to maintain the document up to date with good quality.
> 
> +1
> 
> I cannot expect when someone who knows Korean, understand memory-barrier stuff
> very well and have enough time to reivew comes up. Anyway, if the translation
> has a problem, we could fix it later so I really appreciate SeongJae's nice
> contribution translated one of hardest document but valuable.
> 
> Acked-by: Minchan Kim 

Very good, I have added your Acked-by.

Thanx, Paul

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2 0/5] Add Korean translation of memory-barriers.txt

2016-03-14 Thread Minchan Kim
On Tue, Mar 15, 2016 at 06:52:11AM +0900, SeongJae Park wrote:
> On Tue, Mar 15, 2016 at 5:17 AM, Paul E. McKenney
>  wrote:
> > On Fri, Mar 11, 2016 at 12:06:55AM +0900, SeongJae Park wrote:
> >> This patchset aims to add Korean translation of memory-barriers document.
> >>
> >> The patchset starts from fixing minor and trivial problems in the original
> >> document that found during translation.  After that, the final patch adds 
> >> the
> >> Korean translation of the document.
> >>
> >> The patches are based on recent next tree:
> >> 0f6dd067b9c3c712b1177fa2fc0deb21805c771c ("Add linux-next specific files 
> >> for
> >> 20160309")
> >
> > Queued, thank you!  I am going to have to trust you on the Korean, good
> > thing you list yourself as maintainer.  ;-)
> 
> Thank you, Paul!  I believe this change may help future Korean hackers.  Also,
> I will do my best to maintain the document up to date with good quality.

+1

I cannot expect when someone who knows Korean, understand memory-barrier stuff
very well and have enough time to reivew comes up. Anyway, if the translation
has a problem, we could fix it later so I really appreciate SeongJae's nice
contribution translated one of hardest document but valuable.

Acked-by: Minchan Kim 
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v2 0/5] Add Korean translation of memory-barriers.txt

2016-03-14 Thread SeongJae Park
On Tue, Mar 15, 2016 at 5:17 AM, Paul E. McKenney
 wrote:
> On Fri, Mar 11, 2016 at 12:06:55AM +0900, SeongJae Park wrote:
>> This patchset aims to add Korean translation of memory-barriers document.
>>
>> The patchset starts from fixing minor and trivial problems in the original
>> document that found during translation.  After that, the final patch adds the
>> Korean translation of the document.
>>
>> The patches are based on recent next tree:
>> 0f6dd067b9c3c712b1177fa2fc0deb21805c771c ("Add linux-next specific files for
>> 20160309")
>
> Queued, thank you!  I am going to have to trust you on the Korean, good
> thing you list yourself as maintainer.  ;-)

Thank you, Paul!  I believe this change may help future Korean hackers.  Also,
I will do my best to maintain the document up to date with good quality.


Thanks,
SeongJae Park

>
> Thanx, Paul
>
>> SeongJae Park (5):
>>   doc/memory-barriers: fix missed renaming: s/lock/acquire
>>   doc/memory-barriers: add missed subsection in TOC
>>   doc/memory-barriers: fix typo
>>   doc/memory-barriers: Insert white spaces consistently
>>   Doc/memory-barriers: add Korean translation
>>
>>  Documentation/ko_KR/memory-barriers.txt | 3048 
>> +++
>>  Documentation/memory-barriers.txt   |   66 +-
>>  2 files changed, 3083 insertions(+), 31 deletions(-)
>>  create mode 100644 Documentation/ko_KR/memory-barriers.txt
>>
>> --
>> 1.9.1
>>
>
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [v3] pstore-ram: add Device Tree bindings

2016-03-14 Thread Brian Norris
Hi Greg,

On Thu, Jan 07, 2016 at 03:40:56PM -0800, Greg Hackmann wrote:
> ramoops is one of the remaining places where ARM vendors still rely on
> board-specific shims.  Device Tree lets us replace those shims with
> generic code.
> 
> These bindings mirror the ramoops module parameters, with two small
> differences:
> 
> (1) dump_oops becomes an optional "no-dump-oops" property, since ramoops
> sets dump_oops=1 by default.
> 
> (2) mem_type=1 becomes the more self-explanatory "unbuffered" property.
> 
> Signed-off-by: Greg Hackmann 
> Acked-by: Kees Cook 
> 
> ---
> Changes in V3:
> - documentation fixes
> - look for "no-ram-oops" property as documented
> 
> Changes in V2:
> - make DT binding documentation more generic
> 
>  Documentation/devicetree/bindings/misc/ramoops.txt |  43 
>  Documentation/ramoops.txt  |   6 +-
>  fs/pstore/ram.c| 110 
> -
>  3 files changed, 155 insertions(+), 4 deletions(-)
>  create mode 100644 Documentation/devicetree/bindings/misc/ramoops.txt
> 

[...]

> diff --git a/fs/pstore/ram.c b/fs/pstore/ram.c
> index 319c3a6..0f2912c 100644
> --- a/fs/pstore/ram.c
> +++ b/fs/pstore/ram.c
> @@ -34,6 +34,8 @@
>  #include 
>  #include 
>  #include 
> +#include 
> +#include 
>  
>  #define RAMOOPS_KERNMSG_HDR ""
>  #define MIN_MEM_SIZE 4096UL
> @@ -458,15 +460,112 @@ static int ramoops_init_prz(struct device *dev, struct 
> ramoops_context *cxt,
>   return 0;
>  }
>  
> +static int ramoops_parse_dt_size(struct platform_device *pdev,
> + const char *propname, unsigned long *val)
> +{
> + u64 val64;
> + int ret;
> +
> + ret = of_property_read_u64(pdev->dev.of_node, propname, &val64);
> + if (ret == -EINVAL) {
> + *val = 0;
> + return 0;
> + } else if (ret != 0) {
> + dev_err(&pdev->dev, "failed to parse property %s: %d\n",
> + propname, ret);
> + return ret;
> + }
> +
> + if (val64 > ULONG_MAX) {
> + dev_err(&pdev->dev, "invalid %s %llu\n", propname, val64);
> + return -EOVERFLOW;
> + }
> +
> + *val = val64;
> + return 0;
> +}
> +
> +static int ramoops_parse_dt(struct platform_device *pdev,
> + struct ramoops_platform_data *pdata)
> +{
> + struct device_node *of_node = pdev->dev.of_node;
> + struct device_node *mem_region;
> + struct resource res;
> + u32 ecc_size;
> + int ret;
> +
> + dev_dbg(&pdev->dev, "using Device Tree\n");
> +
> + mem_region = of_parse_phandle(of_node, "memory-region", 0);
> + if (!mem_region) {
> + dev_err(&pdev->dev, "no memory-region phandle\n");
> + return -ENODEV;
> + }
> +
> + ret = of_address_to_resource(mem_region, 0, &res);
> + of_node_put(mem_region);
> + if (ret) {
> + dev_err(&pdev->dev, "failed to translate memory-region to 
> resource: %d\n",
> + ret);
> + return ret;
> + }
> +
> + pdata->mem_size = resource_size(&res);
> + pdata->mem_address = res.start;
> + pdata->mem_type = of_property_read_bool(of_node, "unbuffered");
> + pdata->dump_oops = !of_property_read_bool(of_node, "no-dump-oops");
> +
> + ret = ramoops_parse_dt_size(pdev, "record-size", &pdata->record_size);
> + if (ret < 0)
> + return ret;
> +
> + ret = ramoops_parse_dt_size(pdev, "console-size", &pdata->console_size);
> + if (ret < 0)
> + return ret;
> +
> + ret = ramoops_parse_dt_size(pdev, "ftrace-size", &pdata->ftrace_size);
> + if (ret < 0)
> + return ret;
> +
> + ret = ramoops_parse_dt_size(pdev, "pmsg-size", &pdata->pmsg_size);
> + if (ret < 0)
> + return ret;
> +
> + ret = of_property_read_u32(of_node, "ecc-size", &ecc_size);
> + if (ret == 0) {
> + if (ecc_size > INT_MAX) {
> + dev_err(&pdev->dev, "invalid ecc-size %u\n", ecc_size);
> + return -EOVERFLOW;
> + }
> + pdata->ecc_info.ecc_size = ecc_size;
> + } else if (ret != -EINVAL) {
> + return ret;
> + }
> +
> + return 0;
> +}
> +
>  static int ramoops_probe(struct platform_device *pdev)
>  {
>   struct device *dev = &pdev->dev;
> - struct ramoops_platform_data *pdata = pdev->dev.platform_data;
> + struct ramoops_platform_data *pdata = platform_get_drvdata(pdev);

^^^ This is wrong. You don't set drvdata until later. This crashes
(e.g.) the Pixel 2, which uses platform data, not DT.

>   struct ramoops_context *cxt = &oops_cxt;
>   size_t dump_mem_sz;
>   phys_addr_t paddr;
>   int err = -EINVAL;
>  
> + if (dev->of_node && !pdata) {
> + pdata = devm_kzalloc(&pdev->dev, sizeof(*pdata), GFP_KERNEL);
> + if (!pdata) {
> + err = -ENOMEM;
> + goto fail_o

Re: [PATCH v2 0/5] Add Korean translation of memory-barriers.txt

2016-03-14 Thread Paul E. McKenney
On Fri, Mar 11, 2016 at 12:06:55AM +0900, SeongJae Park wrote:
> This patchset aims to add Korean translation of memory-barriers document.
> 
> The patchset starts from fixing minor and trivial problems in the original
> document that found during translation.  After that, the final patch adds the
> Korean translation of the document.
> 
> The patches are based on recent next tree:
> 0f6dd067b9c3c712b1177fa2fc0deb21805c771c ("Add linux-next specific files for
> 20160309")

Queued, thank you!  I am going to have to trust you on the Korean, good
thing you list yourself as maintainer.  ;-)

Thanx, Paul

> SeongJae Park (5):
>   doc/memory-barriers: fix missed renaming: s/lock/acquire
>   doc/memory-barriers: add missed subsection in TOC
>   doc/memory-barriers: fix typo
>   doc/memory-barriers: Insert white spaces consistently
>   Doc/memory-barriers: add Korean translation
> 
>  Documentation/ko_KR/memory-barriers.txt | 3048 
> +++
>  Documentation/memory-barriers.txt   |   66 +-
>  2 files changed, 3083 insertions(+), 31 deletions(-)
>  create mode 100644 Documentation/ko_KR/memory-barriers.txt
> 
> -- 
> 1.9.1
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 1/1] hwmon: add support for Sensirion SHT3x sensors

2016-03-14 Thread Guenter Roeck
Hi Pascal,

On Mon, Mar 14, 2016 at 03:28:52PM +, Pascal Sachs wrote:
> Hi Guenter
> 
> Thank you for the fast code review.
> During extended testing of the updated driver we found some other minor 
> issues with the alert feature we would like to fix before submitting again.
> 
Take your time - you missed the commit window anyway.

> We as well have to update our submission process, since the company mail 
> server converts tabs to whitespaces and adds this confidentiality message to 
> the end.
> I am very sorry about that, but I did not knew that.
> 
No problem. Must be a server from that company in Redmond, WA ;-).

In case it helps, I use "git send-email" in combination with msmtp,
which in turn is configured to send mail either through a gmail account
or, if that happens to be tagged as spam source, through a web hosting
account.

Guenter
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v8 08/10] tpm: Proxy driver for supporting multiple emulated TPMs

2016-03-14 Thread Jarkko Sakkinen
On Sun, Mar 13, 2016 at 06:54:38PM -0400, Stefan Berger wrote:
> This patch implements a proxy driver for supporting multiple emulated TPMs
> in a system.
> 
> The driver implements a device /dev/vtpmx that is used to created
> a client device pair /dev/tpmX (e.g., /dev/tpm10) and a server side that
> is accessed using a file descriptor returned by an ioctl.
> The device /dev/tpmX is the usual TPM device created by the core TPM
> driver. Applications or kernel subsystems can send TPM commands to it
> and the corresponding server-side file descriptor receives these
> commands and delivers them to an emulated TPM.

Tested-by: Jarkko Sakkinen 

My testing procedure was:

* Wine running TPM 2.0 simulator on the host side. [1]
* QEMU running an OS image with this patch. [2]
* Wrote a script for proxying the simulator: tpm2-simulator-vtpm. [3]
* Run some smoke tests: python -m unittest -v tpm2_smoke. [3]

[1] 
http://research.microsoft.com/en-us/downloads/35116857-e544-4003-8e7b-584182dc6833/
[2] git://git.infradead.org/users/jjs/buildroot-tpmdd.git
[3] git://git.infradead.org/users/jjs/tpm2-scripts.git

/Jarkko

> Signed-off-by: Stefan Berger 
> CC: linux-ker...@vger.kernel.org
> CC: linux-doc@vger.kernel.org
> CC: linux-...@vger.kernel.org
> ---
>  drivers/char/tpm/Kconfig  |  10 +
>  drivers/char/tpm/Makefile |   1 +
>  drivers/char/tpm/tpm_vtpm_proxy.c | 572 
> ++
>  include/uapi/linux/Kbuild |   1 +
>  include/uapi/linux/vtpm_proxy.h   |  42 +++
>  5 files changed, 626 insertions(+)
>  create mode 100644 drivers/char/tpm/tpm_vtpm_proxy.c
>  create mode 100644 include/uapi/linux/vtpm_proxy.h

/Jarkko
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


AW: [PATCH 1/1] hwmon: add support for Sensirion SHT3x sensors

2016-03-14 Thread Pascal Sachs
Hi Guenter

Thank you for the fast code review.
During extended testing of the updated driver we found some other minor issues 
with the alert feature we would like to fix before submitting again.

We as well have to update our submission process, since the company mail server 
converts tabs to whitespaces and adds this confidentiality message to the end.
I am very sorry about that, but I did not knew that.

Regards,
Pascal

Von: Guenter Roeck [li...@roeck-us.net]
Gesendet: Donnerstag, 10. März 2016 20:14
An: Pascal Sachs
Cc: Jean Delvare; Jonathan Corbet; lm-sens...@lm-sensors.org; 
linux-doc@vger.kernel.org; linux-ker...@vger.kernel.org; David Frey
Betreff: Re: [PATCH 1/1] hwmon: add support for Sensirion SHT3x sensors

On Thu, Mar 10, 2016 at 02:56:43PM +, Pascal Sachs wrote:
> From: David Frey 
>
> This driver implements support for the Sensirion SHT3x-DIS chip,
> a humidity and temperature sensor. Temperature is measured
> in degrees Celsius, relative humidity is expressed as a percentage.
> In the sysfs interface, all values are scaled by 1000,
> i.e. the value for 31.5 degrees Celsius is 31500.
>

Your patch is whitespace damaged (spaces instead of tabs). Please fix
in the next revision.

> Signed-off-by: Pascal Sachs 
> ---
> Patch was generated against kernel v4.5-rc7
>
>  Documentation/hwmon/sht3x   |  42 
>  drivers/hwmon/Kconfig   |  10 +
>  drivers/hwmon/Makefile  |   1 +
>  drivers/hwmon/sht3x.c   | 389 
> 
>  include/linux/platform_data/sht3x.h |  23 +++
>  5 files changed, 465 insertions(+)
>  create mode 100644 Documentation/hwmon/sht3x
>  create mode 100644 drivers/hwmon/sht3x.c
>  create mode 100644 include/linux/platform_data/sht3x.h
>
> diff --git a/Documentation/hwmon/sht3x b/Documentation/hwmon/sht3x
> new file mode 100644
> index 000..6023862
> --- /dev/null
> +++ b/Documentation/hwmon/sht3x
> @@ -0,0 +1,42 @@
> +Kernel driver sht3x
> +===
> +
> +Supported chips:
> +  * Sensirion SHT3x-DIS
> +Prefix: 'sht3x'
> +Addresses scanned: none
> +Datasheet: 
> http://www.sensirion.com/fileadmin/user_upload/customers/sensirion/Dokumente/Humidity/Sensirion_Humidity_Datasheet_SHT3x_DIS.pdf
> +
> +Author:
> +  David Frey 
> +
> +Description
> +---
> +
> +This driver implements support for the Sensirion SHT3x-DIS chip, a humidity
> +and temperature sensor. Temperature is measured in degrees celsius, relative
> +humidity is expressed as a percentage. In the sysfs interface, all values are
> +scaled by 1000, i.e. the value for 31.5 degrees celsius is 31500.
> +
> +The device communicates with the I2C protocol. Sensors can have the I2C
> +addresses 0x44 or 0x45, depending on the wiring. See
> +Documentation/i2c/instantiating-devices for methods to instantiate the 
> device.
> +
> +There are two options configurable by means of sht3x_platform_data:
> +1. blocking (pull the I2C clock line down while performing the measurement) 
> or
> +   non-blocking mode. Blocking mode will guarantee the fastest result but
> +   the I2C bus will be busy during that time. By default, non-blocking mode
> +   is used. Make sure clock-stretching works properly on your device if you
> +   want to use blocking mode.
> +2. high or low accuracy. High accuracy is used by default and using it is
> +   strongly recommended.
> +
> +sysfs-Interface
> +---
> +
> +temp1_input:  temperature input
> +humidity1_input:  humidity input
> +high_alert_set:   temperature and humidity at which to set the high alert
> +high_alert_clear: temperature and humidity at which to clear the high alert
> +low_alert_clear:  temperature and humidity at which to clear the low alert
> +low_alert_set:temperature and humidity at which to set the low alert

Please use standard attribute names as documented in
Documentation/hwmon/sysfs-interface. This would be
temp1_{min,max}, temp1_{min,max}_hyst, humidity1_{min,max},
humidity1_{min,max}_hyst.

> diff --git a/drivers/hwmon/Kconfig b/drivers/hwmon/Kconfig
> index 60fb80b..4722b76 100644
> --- a/drivers/hwmon/Kconfig
> +++ b/drivers/hwmon/Kconfig
> @@ -1235,6 +1235,16 @@ config SENSORS_SHTC1
>   This driver can also be built as a module.  If so, the module
>   will be called shtc1.
>
> +config SENSORS_SHT3x
> +   tristate "Sensiron humidity and temperature sensors. SHT3x and 
> compat."
> +   depends on I2C
> +   help
> + If you say yes here you get support for the Sensiron SHT30 and SHT31
> + humidity and temperature sensors.
> +
> + This driver can also be built as a module.  If so, the module
> + will be called sht3x.
> +

Please try to keep in alphabetic order (ahead of SHTC1).

>  config SENSORS_S3C
> tristate "Samsung built-in ADC"
> depends on S3C_ADC
> diff --git a/drivers/hwmon/Makefile b/drivers/hwmon/Makefile
> index 30c94df..8f19eab 100644
> --- a/drivers/hwmon/Makefile
> +++ 

[PATCH 2/9] serial: doc: Un-document obsolete tmpbuf_sem

2016-03-14 Thread Geert Uytterhoeven
uart_info.tmpbuf and uart_info.tmpbuf_sem were removed in v2.6.10, in
full-history-linux commit a797ad7e3ae9cad4 ("[SERIAL] Clean up
serial_core.c write functions.").

Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 6 +-
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index e7c6f86ee06f9927..61d520dea4c6e13a 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -36,8 +36,7 @@ It is the responsibility of the low level hardware driver to 
perform the
 necessary locking using port->lock.  There are some exceptions (which
 are described in the uart_ops listing below.)
 
-There are three locks.  A per-port spinlock, a per-port tmpbuf semaphore,
-and an overall semaphore.
+There are two locks.  A per-port spinlock, and an overall semaphore.
 
 From the core driver perspective, the port->lock locks the following
 data:
@@ -50,9 +49,6 @@ data:
 The low level driver is free to use this lock to provide any additional
 locking.
 
-The core driver uses the info->tmpbuf_sem lock to prevent multi-threaded
-access to the info->tmpbuf bouncebuffer used for port writes.
-
 The port_sem semaphore is used to protect against ports being added/
 removed or reconfigured at inappropriate times. Since v2.6.27, this
 semaphore has been the 'mutex' member of the tty_port struct, and
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 6/9] serial: doc: .break_ctl() is called with port->mutex() held

2016-03-14 Thread Geert Uytterhoeven
Note that mutex_lock() should not be called with interrupts disabled.

Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index 3b08df5bcc17e944..09e73e061fcf795c 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -177,8 +177,7 @@ hardware.
should be terminated when another call is made with a zero
ctl.
 
-   Locking: none.
-   Interrupts: caller dependent.
+   Locking: caller holds port->mutex
This call must not sleep
 
   startup(port)
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 5/9] serial: doc: Document .set_ldisc()

2016-03-14 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 5 +
 1 file changed, 5 insertions(+)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index 3b2a97d5ecc79491..3b08df5bcc17e944 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -259,6 +259,11 @@ hardware.
Interrupts: caller dependent.
This call must not sleep
 
+  set_ldisc(port,termios)
+   Notifier for discipline change. See Documentation/serial/tty.txt.
+
+   Locking: caller holds port->mutex
+
   pm(port,state,oldstate)
Perform any power management related activities on the specified
port.  State indicates the new state (defined by
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 3/9] serial: doc: Document .throttle()

2016-03-14 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 7 +++
 1 file changed, 7 insertions(+)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index 61d520dea4c6e13a..50f3d94ed50b341e 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -126,6 +126,13 @@ hardware.
Interrupts: locally disabled.
This call must not sleep
 
+  throttle(port)
+   Notify the serial driver that input buffers for the line discipline are
+   close to full, and it should somehow signal that no more characters
+   should be sent to the serial port.
+
+   Locking: none.
+
   send_xchar(port,ch)
Transmit a high priority character, even if the port is stopped.
This is used to implement XON/XOFF flow control and tcflow().  If
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 1/9] serial: doc: Un-document non-existing uart_write_console()

2016-03-14 Thread Geert Uytterhoeven
uart_write_console() never existed, not even when the "new
uart_write_console function" was documented.

Fixes: 67ab7f596b6adbae ("[SERIAL] Update serial driver documentation")
Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 5 -
 1 file changed, 5 deletions(-)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index 379468e12680dbfb..e7c6f86ee06f9927 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -28,11 +28,6 @@ The serial core provides a few helper functions.  This 
includes identifing
 the correct port structure (via uart_get_console) and decoding command line
 arguments (uart_parse_options).
 
-There is also a helper function (uart_write_console) which performs a
-character by character write, translating newlines to CRLF sequences.
-Driver writers are recommended to use this function rather than implementing
-their own version.
-
 
 Locking
 ---
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 9/9] serial: doc: Correct return type of mctrl_gpio_to_gpiod()

2016-03-14 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index ba84d1f38ca1d1e6..65de49a4b39e5baf 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -462,7 +462,8 @@ mctrl_gpio_free(dev, gpios):
this function.
 
 mctrl_gpio_to_gpiod(gpios, gidx)
-   This returns the gpio structure associated to the modem line index.
+   This returns the gpio_desc structure associated to the modem line
+   index.
 
 mctrl_gpio_set(gpios, mctrl):
This will sets the gpios according to the mctrl state.
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 4/9] serial: doc: Document .unthrottle()

2016-03-14 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 7 +++
 1 file changed, 7 insertions(+)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index 50f3d94ed50b341e..3b2a97d5ecc79491 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -133,6 +133,13 @@ hardware.
 
Locking: none.
 
+  unthrottle(port)
+   Notify the serial driver that characters can now be sent to the serial
+   port without fear of overrunning the input buffers of the line
+   disciplines.
+
+   Locking: none.
+
   send_xchar(port,ch)
Transmit a high priority character, even if the port is stopped.
This is used to implement XON/XOFF flow control and tcflow().  If
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 0/9] serial: doc: Low Level Serial API Documentation Improvements

2016-03-14 Thread Geert Uytterhoeven
Hi Russell, Greg, Jiri, Jon,

This patch series contains improvements to the low level serial driver
API documentation.

Thanks for your comments!

Geert Uytterhoeven (9):
  serial: doc: Un-document non-existing uart_write_console()
  serial: doc: Un-document obsolete tmpbuf_sem
  serial: doc: Document .throttle()
  serial: doc: Document .unthrottle()
  serial: doc: Document .set_ldisc()
  serial: doc: .break_ctl() is called with port->mutex() held
  serial: doc: Spelling s/divsor/divisor/
  serial: doc: Grammar s/function are/functions are/
  serial: doc: Correct return type of mctrl_gpio_to_gpiod()

 Documentation/serial/driver | 40 +---
 1 file changed, 25 insertions(+), 15 deletions(-)

-- 
1.9.1

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- ge...@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 7/9] serial: doc: Spelling s/divsor/divisor/

2016-03-14 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index 09e73e061fcf795c..3706a465fe2d7427 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -380,7 +380,7 @@ uart_get_baud_rate(port,termios,old,min,max)
Interrupts: n/a
 
 uart_get_divisor(port,baud)
-   Return the divsor (baud_base / baud) for the specified baud
+   Return the divisor (baud_base / baud) for the specified baud
rate, appropriately rounded.
 
If 38400 baud and custom divisor is selected, return the
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[PATCH 8/9] serial: doc: Grammar s/function are/functions are/

2016-03-14 Thread Geert Uytterhoeven
Signed-off-by: Geert Uytterhoeven 
---
 Documentation/serial/driver | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/serial/driver b/Documentation/serial/driver
index 3706a465fe2d7427..ba84d1f38ca1d1e6 100644
--- a/Documentation/serial/driver
+++ b/Documentation/serial/driver
@@ -458,7 +458,7 @@ mctrl_gpio_init(port, idx):
 
 mctrl_gpio_free(dev, gpios):
This will free the requested gpios in mctrl_gpio_init().
-   As devm_* function are used, there's generally no need to call
+   As devm_* functions are used, there's generally no need to call
this function.
 
 mctrl_gpio_to_gpiod(gpios, gidx)
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH v15 1/3] drm: rockchip: Add basic drm driver

2016-03-14 Thread Tomeu Vizoso
On 2 December 2014 at 10:15, Mark Yao  wrote:
> diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_vop.c 
> b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
> new file mode 100644
> index 000..e7ca25b
> --- /dev/null
> +++ b/drivers/gpu/drm/rockchip/rockchip_drm_vop.c
> @@ -0,0 +1,1455 @@
...
> +static bool vop_crtc_mode_fixup(struct drm_crtc *crtc,
> +   const struct drm_display_mode *mode,
> +   struct drm_display_mode *adjusted_mode)
> +{
> +   if (adjusted_mode->htotal == 0 || adjusted_mode->vtotal == 0)
> +   return false;

Hi Mark,

what's the rationale for this?

Disabling a CRTC as in [0] will cause mode_fixup() to be called with
an empty mode, failing that test.

Removing the check seems to get things working fine for a short while,
but a later modeset invariably gets the VOP to hang (as reported by
[1]).

Do you know why that check was put in place and what exactly could be
causing the hw to hang?

[0] 
https://cgit.freedesktop.org/xorg/app/intel-gpu-tools/tree/lib/igt_kms.c#n1616
[1] 
https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/drivers/gpu/drm/rockchip/rockchip_drm_vop.c#n873

Thanks,

Tomeu

> +
> +   return true;
> +}
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [RESEND PATCH V4 4/4] coresight-stm: adding driver for CoreSight STM component

2016-03-14 Thread Michael Williams
Reviewed-by: Michael Williams 

This resend addresses my earlier concerns.

> -Original Message-
> From: Chunyan Zhang [mailto:zhang.chun...@linaro.org]
> Sent: 08 March 2016 06:34
> To: mathieu.poir...@linaro.org; alexander.shish...@linux.intel.com
> Cc: Mike Leach; Michael Williams; Al Grant; t...@ti.com; nicolas.gu...@st.com;
> prat...@codeaurora.org; zhang.l...@gmail.com; linux-ker...@vger.kernel.org; 
> linux-arm-
> ker...@lists.infradead.org; linux-...@vger.kernel.org; 
> linux-doc@vger.kernel.org
> Subject: [RESEND PATCH V4 4/4] coresight-stm: adding driver for CoreSight STM 
> component
>
> From: Pratik Patel 

[snip]

Mike.
--
Michael Williams  Principal Engineer   ARM Limited
www.arm.com The Architecture For The Digital World
IMPORTANT NOTICE: The contents of this email and any attachments are 
confidential and may also be privileged. If you are not the intended recipient, 
please notify the sender immediately and do not disclose the contents to any 
other person, use it for any purpose, or store or copy the information in any 
medium. Thank you.

--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 19/22] ncr5380: Update usage documentation

2016-03-14 Thread Hannes Reinecke
On 03/14/2016 05:27 AM, Finn Thain wrote:
> Update kernel parameter documentation for atari_scsi, mac_scsi and
> g_NCR5380 drivers. Remove duplication.
> 
> Signed-off-by: Finn Thain 
> 
> ---
>  Documentation/scsi/g_NCR5380.txt   |   17 ++-
>  Documentation/scsi/scsi-parameters.txt |   11 +++---
>  drivers/scsi/g_NCR5380.c   |   36 
> -
>  3 files changed, 16 insertions(+), 48 deletions(-)
> 
Reviewed-by: Hannes Reinecke 

Cheers,

Hannes
-- 
Dr. Hannes ReineckeTeamlead Storage & Networking
h...@suse.de   +49 911 74053 688
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton
HRB 21284 (AG Nürnberg)
--
To unsubscribe from this list: send the line "unsubscribe linux-doc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html