Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2927021pxa; Tue, 18 Aug 2020 01:34:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy1K2wiC7JqLJ4WkR6NKIS/FlN08i3lZB2bLClYpai4t3AEkoR/Pa/+iM1urm7lgOpqtEAV X-Received: by 2002:a17:906:386:: with SMTP id b6mr18641196eja.538.1597739679584; Tue, 18 Aug 2020 01:34:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597739679; cv=none; d=google.com; s=arc-20160816; b=qCb7cZcmkKsq2UR9MNvjTJhq5HqO3m/ZNNNSDUeg14+ShrbQyP2quF2f+olnOWF68a 71ptlkZyhVozJRyYG/R2L8xeXgEKwBN7kuhfXQZpPBhsAv/8CuG2S0xSDcffn/M6ZWMj 4pTArqhcuiV7rN6EVQgE0DH2OC5aAdFKxLlGk4zhQKb73Cg1nN8p+741bRpoV5zsCN6r Euw4UeQMl9IkFXY1ReJrOsvJEJNDBNANe2wFDtGm4BjvjTBBTKa3GqK19Qva2IeXidxI oaLawq90o6fnKtCJAOeJ3kgkxuEm/gb1Nsb2MvEPAagAUjWa9NjGgbQR4lxb7BsUsHhJ gq4g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=banMpyeA8Q0/pOWW4Ugj75v0FAal7gG7gh7TQVBuQjE=; b=le6rm6h0ihEBGsMNTLADxU+nB9MNtFz0ONBxSMgBVWEJ4+20CMhgaS/nmpkk4Xc2Y3 KbX9ka+hqkC+MXrqfn7mnbLqYfeVWJjS5QW05PKDDpuQTe7VP4oKLvtYdYVCgH4Zk2jF O2COqDxkCwL2KhtJpxjFLkn2oVQCBOMAdm3Z1+JYSeGmMlHQI2NlX+U0VI5NOTHthDht kG9scubgo5ukwH0f1c4bkAbsqNnLEKoxpmRQqlrDr4PXD5EM0ebzb3u+8v2NdojOsSiz YbIKCLQPwZHDOHsTjSJkQPpT0BjQGM6HkroeKDJSMXiHd/FKSujsA82G8wwBa+u2FUY8 4bBw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=rS9YImYI; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id si30si13119045ejb.569.2020.08.18.01.34.16; Tue, 18 Aug 2020 01:34:39 -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=pass header.i=@kernel.org header.s=default header.b=rS9YImYI; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726482AbgHRIbm (ORCPT + 99 others); Tue, 18 Aug 2020 04:31:42 -0400 Received: from mail.kernel.org ([198.145.29.99]:35574 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726145AbgHRIbl (ORCPT ); Tue, 18 Aug 2020 04:31:41 -0400 Received: from localhost (unknown [122.171.38.130]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9CACB2067C; Tue, 18 Aug 2020 08:31:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597739500; bh=cjUtFFEhvcQwQkw1VVlJuHM2ITwJUHRyNQQzIFZR3Vs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=rS9YImYIwCC+kc9eRT1/QzM2OjBOFNhgOyh7n7hkABGdbsnSLinFAOHFB5Z4HTCiK mChIGSni7plQROsSHXIiVtJcPO2ivbqH/f9kXEoeAWTdKJ5mHMrB7KUQoho54RI7uN BSxuKNU76veor9YUNXy4RG9R7Tq7Yrb6nXaK/YHE= Date: Tue, 18 Aug 2020 14:01:36 +0530 From: Vinod Koul To: "Liao, Bard" Cc: Bard Liao , "alsa-devel@alsa-project.org" , "linux-kernel@vger.kernel.org" , "tiwai@suse.de" , "broonie@kernel.org" , "gregkh@linuxfoundation.org" , "jank@cadence.com" , "srinivas.kandagatla@linaro.org" , "rander.wang@linux.intel.com" , "ranjani.sridharan@linux.intel.com" , "hui.wang@canonical.com" , "pierre-louis.bossart@linux.intel.com" , "Kale, Sanyog R" , "Lin, Mengdong" Subject: Re: [PATCH 1/2] soundwire: add definition for maximum number of ports Message-ID: <20200818083136.GX2639@vkoul-mobl> References: <20200817174727.15139-1-yung-chuan.liao@linux.intel.com> <20200817174727.15139-2-yung-chuan.liao@linux.intel.com> <20200818063538.GV2639@vkoul-mobl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 18-08-20, 06:53, Liao, Bard wrote: > > -----Original Message----- > > From: Vinod Koul > > Sent: Tuesday, August 18, 2020 2:36 PM > > To: Bard Liao > > Cc: alsa-devel@alsa-project.org; linux-kernel@vger.kernel.org; tiwai@suse.de; > > broonie@kernel.org; gregkh@linuxfoundation.org; jank@cadence.com; > > srinivas.kandagatla@linaro.org; rander.wang@linux.intel.com; > > ranjani.sridharan@linux.intel.com; hui.wang@canonical.com; pierre- > > louis.bossart@linux.intel.com; Kale, Sanyog R ; Lin, > > Mengdong ; Liao, Bard > > Subject: Re: [PATCH 1/2] soundwire: add definition for maximum number of > > ports > > > > On 18-08-20, 01:47, Bard Liao wrote: > > > From: Pierre-Louis Bossart > > > > > > A Device may have at most 15 physical ports (DP0, DP1..DP14). > > > > > > Signed-off-by: Pierre-Louis Bossart > > > > > > Reviewed-by: Rander Wang > > > Reviewed-by: Guennadi Liakhovetski > > > > > > Signed-off-by: Bard Liao > > > --- > > > include/linux/soundwire/sdw.h | 3 ++- > > > 1 file changed, 2 insertions(+), 1 deletion(-) > > > > > > diff --git a/include/linux/soundwire/sdw.h > > > b/include/linux/soundwire/sdw.h index 76052f12c9f7..0aa4c6af7554 > > > 100644 > > > --- a/include/linux/soundwire/sdw.h > > > +++ b/include/linux/soundwire/sdw.h > > > @@ -38,7 +38,8 @@ struct sdw_slave; > > > #define SDW_FRAME_CTRL_BITS 48 > > > #define SDW_MAX_DEVICES 11 > > > > > > -#define SDW_VALID_PORT_RANGE(n) ((n) <= 14 && (n) >= 1) > > > +#define SDW_MAX_PORTS 15 > > > +#define SDW_VALID_PORT_RANGE(n) ((n) < > > SDW_MAX_PORTS && (n) >= 1) > > > > What is the use of this one if we are allocating all ports always, Also, I dont > > see it used in second patch? > > It is used in drivers/soundwire/stream.c and drivers/soundwire/debugfs.c. Ah overlooked that it is modified, pls ignore this comment -- ~Vinod