diff mbox series

[1/5] dt-bindings: vendor: Escape single quote

Message ID 20190525134140.6220-1-maxime.ripard@bootlin.com (mailing list archive)
State New, archived
Headers show
Series [1/5] dt-bindings: vendor: Escape single quote | expand

Commit Message

Maxime Ripard May 25, 2019, 1:41 p.m. UTC
Single quotes need to be escaped in YAML, make sure it's the case.

Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
---
 Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Rob Herring (Arm) May 26, 2019, 4:04 p.m. UTC | #1
On Sat, 25 May 2019 15:41:36 +0200, Maxime Ripard wrote:
> Single quotes need to be escaped in YAML, make sure it's the case.
> 
> Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
> ---
>  Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 

Applied, thanks.

Rob
Rob Herring June 11, 2019, 9:18 p.m. UTC | #2
On Sat, May 25, 2019 at 7:41 AM Maxime Ripard <maxime.ripard@bootlin.com> wrote:
>
> Single quotes need to be escaped in YAML, make sure it's the case.
>
> Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
> ---
>  Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> index 19cc3240a445..ec53162e900d 100644
> --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
> +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> @@ -672,7 +672,7 @@ patternProperties:
>    "^plantower,.*":
>      description: Plantower Co., Ltd
>    "^plathome,.*":
> -    description: Plat'Home Co., Ltd.
> +    description: Plat\'Home Co., Ltd.

Actually, I think this isn't necessary. Where was this causing a
problem? Only in single quoted strings do you have to escape a single
quote and it is done with 2 single quotes rather than a backslash.
However, to maintain a json compatible subset of yaml, maybe we do
need it.

Rob
Maxime Ripard June 12, 2019, 3:48 p.m. UTC | #3
Hi,

On Tue, Jun 11, 2019 at 03:18:51PM -0600, Rob Herring wrote:
> On Sat, May 25, 2019 at 7:41 AM Maxime Ripard <maxime.ripard@bootlin.com> wrote:
> >
> > Single quotes need to be escaped in YAML, make sure it's the case.
> >
> > Signed-off-by: Maxime Ripard <maxime.ripard@bootlin.com>
> > ---
> >  Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> > index 19cc3240a445..ec53162e900d 100644
> > --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
> > +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> > @@ -672,7 +672,7 @@ patternProperties:
> >    "^plantower,.*":
> >      description: Plantower Co., Ltd
> >    "^plathome,.*":
> > -    description: Plat'Home Co., Ltd.
> > +    description: Plat\'Home Co., Ltd.
>
> Actually, I think this isn't necessary. Where was this causing a
> problem? Only in single quoted strings do you have to escape a single
> quote and it is done with 2 single quotes rather than a backslash.

I guess I misread the YAML spec though... Sorry.

> However, to maintain a json compatible subset of yaml, maybe we do
> need it.

If you don't want it anymore, I guess we can drop or revert it.

Maxime

--
Maxime Ripard, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
index 19cc3240a445..ec53162e900d 100644
--- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
+++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
@@ -672,7 +672,7 @@  patternProperties:
   "^plantower,.*":
     description: Plantower Co., Ltd
   "^plathome,.*":
-    description: Plat'Home Co., Ltd.
+    description: Plat\'Home Co., Ltd.
   "^plda,.*":
     description: PLDA
   "^plx,.*":