Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp1057877ybi; Sat, 27 Jul 2019 01:52:17 -0700 (PDT) X-Google-Smtp-Source: APXvYqyCPhvaLf4PUy8uaZ27pd58NyKBdPKgO7MQ3/iZoD04U6RrPzGSqvI3n4N7KhaiMeupXdY2 X-Received: by 2002:a63:ff65:: with SMTP id s37mr53495744pgk.102.1564217537239; Sat, 27 Jul 2019 01:52:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564217537; cv=none; d=google.com; s=arc-20160816; b=MrI/X6cZSOmOqQmhBxMSF4rK1P3wn5DaMmEwjOSgHhnJtpmkzgVBoFJV7Yhg5e/MME hC1PzU92NuosJDt9CaZaeOutPY09t79PEWH1TGrN00CfMwCFWSd5wBdS94ajjim8y0hk 4P2y2o2Xoj1t3+kcQMmfWHn1+zxU3jTV+O+8TEMH0NgdQttYnbI4k0507fG9DEPeXF25 9+lmdMEkm79d59WzBI9Yb9AcTJBkeDLVneL4wOcQW8uzNjFSdOpI9qWBHrPYwwT8QcZ8 I4tnuRxH53y4LX5+nGIHtI6bJJ+25UayKwcJBVxn83GZEg7UZys6oJXnUz7Hjz3RrymS 89RA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=4UPNTz4TdgzIZmMBXeTwtZgEi0MW7Uef+jaY95Hrkds=; b=OgSM1j+XZfW5FoOpoAtl9DKLnV+yx67CyeCKXgYsYpSy/q3UoYe5Zk1rgLQ8aAXRCb rcBV5S4rshHNOz9qfMRfbkBgScsf/ygkCswiDl7LUYcm7YbXvpiDs7X9c6tPshRum/T9 eQ0kZgn8+5dcA7ZhR7LpU1wr42GbDVUeFPblOyfJ+AdyM6d018mB+qg++iexLxr9ndto 0UbmN5nzMsUx/iOt2zzrzo6qMjtyrTWDdOOwgVq3+8pnLjnCr801BQMrzLLZ1zCOIfjU 8ot7SdbrmpmmAVnarTXGrof1wCCY9xgwBtgMt69+hZ5tG+W4BY6LiefEiLmKzEvOCZoB l8uQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@brainfault-org.20150623.gappssmtp.com header.s=20150623 header.b=RmkjqWEy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q10si8970999pff.223.2019.07.27.01.51.59; Sat, 27 Jul 2019 01:52:17 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@brainfault-org.20150623.gappssmtp.com header.s=20150623 header.b=RmkjqWEy; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728423AbfG0IuM (ORCPT + 99 others); Sat, 27 Jul 2019 04:50:12 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:55142 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727885AbfG0IuM (ORCPT ); Sat, 27 Jul 2019 04:50:12 -0400 Received: by mail-wm1-f65.google.com with SMTP id p74so49756036wme.4 for ; Sat, 27 Jul 2019 01:50:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brainfault-org.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=4UPNTz4TdgzIZmMBXeTwtZgEi0MW7Uef+jaY95Hrkds=; b=RmkjqWEyykTcnQJOzeVJPssrZCe1IDbCTicTgCyB17xg/pyUVbCGsnH85S6mBbL6Fj KMDdamonixrIwb18WueFU7+3xJRnixen9A/u494I7HesUdwH6oame7qDGjhxzrmchGGp lSzjjMflEhF/Gshz2na4TPBgBiTr9MOxr6tyf6VVaKOaRw4mfwABG0fwW7gjolMHhIjb 5q1Q/ANNgTQ1P8AhlvG4TfEqnVVNBALz9zjPimHVxRE6O5YKgCC22ZoGf0+FtozAcCwq FWUUD7tXJ5x4giwLCoyjLx8ak3CrI7Bc8e96iwr1YjUGleMOs8o1srXOiUk6YKt+bVC1 TYRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=4UPNTz4TdgzIZmMBXeTwtZgEi0MW7Uef+jaY95Hrkds=; b=IKddjAg8RCzQj45660Q3dXSRBkuDVZfFv9mM3niTuvUCY0N5r667ghv3pX12VglGkc 3+Zw3glqUsHoqnA60/2JOSLGgW9Q4hmH+nFoJyNov5mJquVSSKcYIFDYwBxxVn1++pIe 6HcDqhgXBO9Dig+BkYkWw+sfJ2xig24dvmUq5OLJB4HA7Li4PDkkYxzCDZIxiha/kjnW rPEdZeeRoeKFflfIYfUeAwude5cjZSe7OXUMMtFGqn/iQGr+CdwR3Ym4F8R5FkDFPPbE AgKk97QDF2Q6oVvn32oef8wLXYFfD709BhJxwGpcseU3vc2q4glKwdNpVUm6K2WQZjml J25g== X-Gm-Message-State: APjAAAWW29eYMPWVvL+SWCDvXKhaCuyr+lyWf7S9g6wIMds8GOR4oQPg vIqW7biIR6sPfo5oj6IHcpUJ66SGk9vR5m4dbO0= X-Received: by 2002:a1c:9d53:: with SMTP id g80mr84386351wme.103.1564217409437; Sat, 27 Jul 2019 01:50:09 -0700 (PDT) MIME-Version: 1.0 References: <20190726194638.8068-1-atish.patra@wdc.com> <20190726194638.8068-3-atish.patra@wdc.com> In-Reply-To: From: Anup Patel Date: Sat, 27 Jul 2019 14:19:58 +0530 Message-ID: Subject: Re: [PATCH 3/4] RISC-V: Support case insensitive ISA string parsing. To: Paul Walmsley Cc: Anup Patel , Albert Ou , Alan Kao , Greg Kroah-Hartman , Daniel Lezcano , "linux-kernel@vger.kernel.org" , Johan Hovold , Atish Patra , Palmer Dabbelt , "linux-riscv@lists.infradead.org" , Thomas Gleixner , Allison Randal Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Jul 27, 2019 at 1:46 PM Paul Walmsley wrote: > > On Sat, 27 Jul 2019, Anup Patel wrote: > > > If your only objection is uppercase letter not agreeing with YMAL schema > > then why not fix the YMAL schema to have regex for RISC-V ISA string? > > I don't agree with you that the specification compels software to accept > arbitrary case combinations in the riscv,isa DT string. DT describes HW and HW follows RISC-V spec. Enforcing software choices in DT YMAL schema is not correct approach. Some other OS (such as FreeBSD, NetBSD, etc) might choose to go with upper-case characters only in their DTS files. > > > The YMAL schema should not enforce any artificial restriction which is > > theoretically allowed in the RISC-V spec. > > Unless someone can come up with a compelling reason for why restricting > the DT ISA strings to all lowercase letters and numbers is insufficient to > express the full range of options in the spec, the additional complexity > to add mixed-case parsing, both in this patch and in the other patches in > this series, seems pointless. So, using strncasecmp() in-place of strncmp() and using tolower() for each character comparison is complex for you ? Why do we need a pointless restriction in YAML schema ? Regards, Anup