From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 925C3C433EF for ; Wed, 19 Jan 2022 22:25:12 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0E00310EEC0; Wed, 19 Jan 2022 22:25:09 +0000 (UTC) Received: from eu-smtp-delivery-151.mimecast.com (eu-smtp-delivery-151.mimecast.com [185.58.86.151]) by gabe.freedesktop.org (Postfix) with ESMTPS id C9B3C10E3D2 for ; Wed, 19 Jan 2022 22:25:06 +0000 (UTC) Received: from AcuMS.aculab.com (156.67.243.121 [156.67.243.121]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id uk-mta-3-gc2FjgmsNLmz-uRweWCGWA-1; Wed, 19 Jan 2022 22:25:02 +0000 X-MC-Unique: gc2FjgmsNLmz-uRweWCGWA-1 Received: from AcuMS.Aculab.com (fd9f:af1c:a25b:0:994c:f5c2:35d6:9b65) by AcuMS.aculab.com (fd9f:af1c:a25b:0:994c:f5c2:35d6:9b65) with Microsoft SMTP Server (TLS) id 15.0.1497.28; Wed, 19 Jan 2022 22:25:00 +0000 Received: from AcuMS.Aculab.com ([fe80::994c:f5c2:35d6:9b65]) by AcuMS.aculab.com ([fe80::994c:f5c2:35d6:9b65%12]) with mapi id 15.00.1497.028; Wed, 19 Jan 2022 22:25:00 +0000 From: David Laight To: 'Andy Shevchenko' Subject: RE: [PATCH 1/3] lib/string_helpers: Consolidate yesno() implementation Thread-Topic: [PATCH 1/3] lib/string_helpers: Consolidate yesno() implementation Thread-Index: AQHYDUVmV8sHy8JfXU2yTPkp1VbmK6xqitzAgAAAVLCAAC4ygIAAMm1Q Date: Wed, 19 Jan 2022 22:25:00 +0000 Message-ID: <2978e422e33f48f0bd07d937cdab13a5@AcuMS.aculab.com> References: <20220119072450.2890107-1-lucas.demarchi@intel.com> <20220119072450.2890107-2-lucas.demarchi@intel.com> <20220119100102.61f9bfde@gandalf.local.home> <06420a70f4434c2b8590cc89cad0dd6a@AcuMS.aculab.com> <9c26ca9bf75d494ea966059d9bcbc2b5@AcuMS.aculab.com> In-Reply-To: Accept-Language: en-GB, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.202.205.107] MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=C51A453 smtp.mailfrom=david.laight@aculab.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: aculab.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Emma Anholt , David Airlie , "nouveau@lists.freedesktop.org" , Rasmus Villemoes , "dri-devel@lists.freedesktop.org" , Chris Wilson , Vishal Kulkarni , Francis Laniel , Kentaro Takeda , "amd-gfx@lists.freedesktop.org" , Ben Skeggs , Jakub Kicinski , Petr Mladek , Sakari Ailus , Leo Li , "intel-gfx@lists.freedesktop.org" , Raju Rangoju , Lucas De Marchi , 'Steven Rostedt' , Julia Lawall , Rahul Lakkireddy , Rodrigo Vivi , Mikita Lipski , Eryk Brol , Greg Kroah-Hartman , "linux-kernel@vger.kernel.org" , =?iso-8859-1?Q?Christian_K=F6nig?= , Sergey Senozhatsky , "linux-security-module@vger.kernel.org" , "netdev@vger.kernel.org" , Alex Deucher , Andrew Morton , "David S . Miller" Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" > > except '"no\0\0yes" + v * 4' works a bit better. >=20 > Is it a C code obfuscation contest? That would be: =09return &(v * 3)["no\0yes"]; :-) - Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1= PT, UK Registration No: 1397386 (Wales)