Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp90345rwb; Fri, 30 Sep 2022 18:00:54 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6Da2Y6zpvXfNaDjKJ4+NnUL8api2ufQJPmqM7K2ls2NaZwaGHbL482eJ0JCVfOYK5SdpoM X-Received: by 2002:a17:902:cecc:b0:177:f3f4:cc90 with SMTP id d12-20020a170902cecc00b00177f3f4cc90mr11568417plg.83.1664586053983; Fri, 30 Sep 2022 18:00:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664586053; cv=none; d=google.com; s=arc-20160816; b=rQdqlFk2dpYshaqjCIFWzbTaUoBCRrUHugqp3rnBufv+VoTHqQEst6RGk92ncoIvWC l6tUO8YKaT2SH6BmEmhHGF/I4LJZ1zqTf/CmGMlXJ024PNWzvg6tpkKECIWSADS9Zjh2 XWDD5IQB7/5g34yOHcM4SPDBiFL0t6D/VxnymfmIC0Gmqhdpcy5LRvEFoXBYJWsVsTw6 CstTeWBIIuYRbKjbkLRr/nMmGYsASk7BXvmtxWP2pTKc+SaPfk0XG3bAa0S0cS3QQ/VS +WyHhUOtr6XfKSTRWmjUXhUIaQQyvBf7PZb2ebL9nDjisiy+Z6b42O/AJF2tlhEBOAjd Ub+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject; bh=pYP0XQTuP4fT/EE8OAmnsosTvNER7GUwp6MXQPEnn0M=; b=G89jlv0ZpfzVUVzTVQ2uBNIrnUz5hNYYUuqUYJKcjDuI09WbphTYVBr2+Y6ET3tZHV 3oBLKCcgHqV9UpzKhuVzcg7VmwJp0CP2HW0NHmydqPna1VLn1tVnJHmicLTFqJ38Nxto BKxWGXEu4J2I7hlkruM0hMW+lXdUSZfFOOV2gSCq+WGDG9oGwHY13nRSmYQLzomIbYSQ 7oVzDj/9dJTVX1qyp/ILMNrv4n07ff6+qh4r6GncNGy3trBUDBJkFM8kcEelMj4WOooM En4FNgcGVCh0pLLD2npH2OCvTtlGUC+pNGVdjFi6FHEi+/yVncRkm5TLUFDFtspDumRV tySA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id pa17-20020a17090b265100b00202d026ca0fsi3684675pjb.14.2022.09.30.18.00.41; Fri, 30 Sep 2022 18:00:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231743AbiJAArF (ORCPT + 99 others); Fri, 30 Sep 2022 20:47:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42148 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232640AbiJAArE (ORCPT ); Fri, 30 Sep 2022 20:47:04 -0400 Received: from mailgw.kylinos.cn (unknown [124.126.103.232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6B282199CAB; Fri, 30 Sep 2022 17:46:57 -0700 (PDT) X-UUID: 448d8811682a4868826c61f268f50177-20221001 X-CPASD-INFO: 5c76e4d3bd6d4c4f8b400de3277ad8f8@frNxVpJmkmOOhHiwg6Z_oFiTZGBgkIW CdHFXkZJokliVhH5xTV5uYFV9fWtVYV9dYVR6eGxQYmBgZFJ4i3-XblBgXoZgUZB3hKVxVpVilA== X-CLOUD-ID: 5c76e4d3bd6d4c4f8b400de3277ad8f8 X-CPASD-SUMMARY: SIP:-1,APTIP:-2.0,KEY:0.0,FROMBLOCK:1,OB:0.0,URL:-5,TVAL:155. 0,ESV:1.0,ECOM:-5.0,ML:0.0,FD:0.0,CUTS:108.0,IP:-2.0,MAL:-5.0,PHF:-5.0,PHC:-5 .0,SPF:4.0,EDMS:-5,IPLABEL:-2.0,FROMTO:0,AD:0,FFOB:0.0,CFOB:0.0,SPC:0,SIG:-5, AUF:12,DUF:6105,ACD:96,DCD:96,SL:0,EISP:0,AG:0,CFC:0.439,CFSR:0.08,UAT:0,RAF: 2,IMG:-5.0,DFA:0,DTA:0,IBL:-2.0,ADI:-5,SBL:0,REDM:0,REIP:0,ESB:0,ATTNUM:0,EAF :0,CID:-5.0,VERSION:2.3.17 X-CPASD-ID: 448d8811682a4868826c61f268f50177-20221001 X-CPASD-BLOCK: 1000 X-CPASD-STAGE: 1 X-UUID: 448d8811682a4868826c61f268f50177-20221001 X-User: jianghaoran@kylinos.cn Received: from [192.168.1.105] [(183.242.54.212)] by mailgw (envelope-from ) (Generic MTA) with ESMTP id 1962507765; Sat, 01 Oct 2022 08:47:44 +0800 Subject: Re: [PATCH] taprio: Set the value of picos_per_byte before fill sched_entry To: Jakub Kicinski Cc: vinicius.gomes@intel.com, jhs@mojatatu.com, jiri@resnulli.us, davem@davemloft.net, edumazet@google.com, pabeni@redhat.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, vladimir.oltean@nxp.com References: <20220928065830.1544954-1-jianghaoran@kylinos.cn> <20220929191815.51362581@kernel.org> From: jianghaoran Message-ID: <7b707ba4-c3f2-dd17-e3f2-e4d143b76245@kylinos.cn> Date: Sat, 1 Oct 2022 08:42:49 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 MIME-Version: 1.0 In-Reply-To: <20220929191815.51362581@kernel.org> Content-Type: text/plain; charset=gbk; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00,KHOP_HELO_FCRDNS, NICE_REPLY_A,RDNS_DYNAMIC,SPF_HELO_NONE,T_SPF_PERMERROR autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ?? 2022/9/30 ????10:18, Jakub Kicinski ะด??: > On Wed, 28 Sep 2022 14:58:30 +0800 jianghaoran wrote: >> If the value of picos_per_byte is set after fill sched_entry, >> as a result, the min_duration calculated by length_to_duration is 0, >> and the validity of the input interval cannot be judged, >> too small intervals couldn't allow any packet to be transmitted. > > Meaning an invalid configuration is accepted but no packets > can ever be transmitted? Could you make the user-visible > issue clearer? Yes, It's possible that the user specifies an too small interval that couldn't allow any packet to be transmitted.According to the following example, the interval is set to 9, and the network port enp5s0f0 cannot send any data >> It will appear like commit b5b73b26b3ca ("taprio: >> Fix allowing too small intervals") described problem. >> Here is a further modification of this problem. >> >> example: > > Here as well it seems worthwhile to mention what this is an example of. > e.g. "example configuration which will not be able to transmit packets" > >> tc qdisc replace dev enp5s0f0 parent root handle 100 taprio \ >> num_tc 3 \ >> map 2 2 1 0 2 2 2 2 2 2 2 2 2 2 2 2 \ >> queues 1@0 1@1 2@2 \ >> base-time 1528743495910289987 \ >> sched-entry S 01 9 \ >> sched-entry S 02 9 \ >> sched-entry S 04 9 \ >> clockid CLOCK_TAI > > Please add a Fixes tag pointing to the first commit where the issue was > present, and CC Vladimir Oltean on the next > version. > Thank you for your suggestion. I will modify it as suggested