Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp645835pxa; Fri, 14 Aug 2020 13:56:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyFqB50b3lixVA82qsluz6Tld1huKs5wn36nsNFOTsOldqnwEJx2476PZ8gG0rxXFtY7NRj X-Received: by 2002:a17:906:b6c3:: with SMTP id ec3mr4113678ejb.101.1597438605564; Fri, 14 Aug 2020 13:56:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597438605; cv=none; d=google.com; s=arc-20160816; b=rTc+uszTfDkPeB83HY66kFcsB8+lfLH0PJvK8823dkgYViEf8xa9+C7CYyT8UX2TGL HIB55KJgdE05OT0lEC+5wcOD33rwPS4o/Nm6S9ntLScS/QQbpLz5UEFinm4PDYJzoEDW 0FjmHYVilHmEbL/pBD3O8lgq0gCGBO8FAyAeLGteRhB3u4/gmBowCuagReL2iCeS3a0P l6/BsjApz1/Xjp2UF3t2V9KPODa5D4mhO/efJytzhl3fELFuTXWgzQ9OftOWmgyT/bMo 9L+w9Lzxx7jhuP6Et2dNbRgYoUqYZo9pEt8/csV2fXsd9GMrnDvxIa2cdxZXQUAzpqX2 N5/w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:message-id:references :in-reply-to:subject:cc:to:from:date:content-transfer-encoding :mime-version:dkim-signature; bh=XT+q1w9uiKS96sq/j8DMN65NAPFFypW3SJhmAiivFh4=; b=Ix7YxVgBh6a68lfj9S9Hu185zntUl8deYPYLh/lCO2NyTnDDknVQA062DKlr64aetY jCqMpi0K8Ij7bnBcUA0us24jk6pr7JzmXcmbDrxjvwhRc3gGUyZgNQxRWKhnK6ZR5p39 bDRSEC5lnm2EDJHLp617krH+E/CVmmSd4YjsQm5M5z3HPo8Ou1S4sbwh/Nb5B8/BbMMo zsVXAg5xDNc+0nLeYfyRSrPKJJzlQhAIFZ2+hgXj8+GFaffj6hkXYizqEVlbuM33mM1w BIOw3xKVkib9olZPONgjet8QThWMLR6sDFMMdYPiYrvzQxrWbQIQS48NV+lcSDtslfLM WLCA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=VK3To71e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e12si5810963ejd.148.2020.08.14.13.56.23; Fri, 14 Aug 2020 13:56:45 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=VK3To71e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726983AbgHNR45 (ORCPT + 99 others); Fri, 14 Aug 2020 13:56:57 -0400 Received: from m43-7.mailgun.net ([69.72.43.7]:12648 "EHLO m43-7.mailgun.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726717AbgHNR45 (ORCPT ); Fri, 14 Aug 2020 13:56:57 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1597427816; h=Message-ID: References: In-Reply-To: Subject: Cc: To: From: Date: Content-Transfer-Encoding: Content-Type: MIME-Version: Sender; bh=XT+q1w9uiKS96sq/j8DMN65NAPFFypW3SJhmAiivFh4=; b=VK3To71e3UBSst0cj1jfGW8y0qVtuH6suBjbifvSU2ukxb513RbuQMrXhK9YwBXZPzLYkJbP SDFvgsJm0+Jd+yNY4hTZRXHGaejT8LExCpI0qQVUK6h1v08ANTCQYSFCXT0K7ftNv/pp+sxo A0r0anEnpS74r8Yv5qc0rzgXvrs= X-Mailgun-Sending-Ip: 69.72.43.7 X-Mailgun-Sid: WyI0MWYwYSIsICJsaW51eC1rZXJuZWxAdmdlci5rZXJuZWwub3JnIiwgImJlOWU0YSJd Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by smtp-out-n03.prod.us-west-2.postgun.com with SMTP id 5f36d066c85a1092b0a9d12b (version=TLS1.2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256); Fri, 14 Aug 2020 17:56:54 GMT Received: by smtp.codeaurora.org (Postfix, from userid 1001) id CB347C43395; Fri, 14 Aug 2020 17:56:53 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=2.0 tests=ALL_TRUSTED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.codeaurora.org (localhost.localdomain [127.0.0.1]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: tanmay) by smtp.codeaurora.org (Postfix) with ESMTPSA id 0EC35C433C9; Fri, 14 Aug 2020 17:56:53 +0000 (UTC) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Fri, 14 Aug 2020 10:56:52 -0700 From: Tanmay Shah To: Dmitry Baryshkov Cc: swboyd@chromium.org, devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, robdclark@gmail.com, airlied@linux.ie, linux-kernel@vger.kernel.org, abhinavk@codeaurora.org, khsieh@codeaurora.org, seanpaul@chromium.org, daniel@ffwll.ch, Guenter Roeck , Vara Reddy , aravindh@codeaurora.org, freedreno@lists.freedesktop.org, Chandan Uddaraju Subject: Re: [Freedreno] [PATCH v10 2/5] drm/msm/dp: add displayPort driver support In-Reply-To: <324d61b6-fc26-03ea-f8af-ff74a9767da2@linaro.org> References: <20200812044223.19279-1-tanmay@codeaurora.org> <20200812044223.19279-3-tanmay@codeaurora.org> <324d61b6-fc26-03ea-f8af-ff74a9767da2@linaro.org> Message-ID: X-Sender: tanmay@codeaurora.org User-Agent: Roundcube Webmail/1.3.9 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2020-08-14 10:12, Dmitry Baryshkov wrote: > Hello, > > On 12/08/2020 07:42, Tanmay Shah wrote: >> From: Chandan Uddaraju > > [skipped] > >> + } else if ((dp_parser_check_prefix("ctrl", clk_name) || >> + dp_parser_check_prefix("stream", clk_name)) && >> + ctrl_clk_index < ctrl_clk_count) { >> + struct dss_clk *clk = >> + &ctrl_power->clk_config[ctrl_clk_index]; >> + strlcpy(clk->clk_name, clk_name, sizeof(clk->clk_name)); >> + ctrl_clk_index++; >> + >> + if (!strncmp(clk_name, "ctrl_link", >> + strlen("ctrl_link")) || >> + !strncmp(clk_name, "stream_pixel", >> + strlen("ctrl_pixel"))) > > This should be "stream_pixel", I believe. I don't like macros, but > most probably it would help here. Also function/brace alignment could > be better (sorry, it really hides the issue here). > Thanks for reviews and good catch!! I completely missed it when I renamed "ctrl_pixel". Use of "stream_pixel" is very limited. So, instead of macros direct name is used. Fixing function and brace alignment sounds good idea insted. > >> + clk->type = DSS_CLK_PCLK; >> + else >> + clk->type = DSS_CLK_AHB; >> + } >> + }