Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp27188579rwd; Mon, 3 Jul 2023 22:43:29 -0700 (PDT) X-Google-Smtp-Source: APBJJlGbTbYTfcLihXhSiS8T3R2AXkJ9ZTJ0uBAI4GIOgj1IWSZA1BPEoM8jebPh/WzvOPb9lT5U X-Received: by 2002:a17:903:22cc:b0:1b8:9b1b:ae8e with SMTP id y12-20020a17090322cc00b001b89b1bae8emr3831754plg.59.1688449409184; Mon, 03 Jul 2023 22:43:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1688449409; cv=none; d=google.com; s=arc-20160816; b=LOOT8ZceGgmAFfABvTCVsroCQszq7twk/6MeEVVKwxHt46r+gfHjCilsEwrpELfftt gMQfnWu70+0iM5O+d9IR68GU92onoLKOl8kTtn4kw8qtnenZSLYqHiZDMlplmBeEDG0A TsRARL3o+MOssuIzT3mZ4HVHuk17J/S3JkJevlbHMHR5cWlB0tfHZrI+HZJYl5CVX9Hu PA4ZEDTADtUfdEVFKAF9hnu6pl8WAmoPW0ZsDyRIlLyMR6DOLLp2cVNk7scp+826yxZC BrG+YjQ/tm1NvHrO+xfpNoP+5ysUfKK5jKF0PehGkPRTQx/Z74jQxJ2KQFZEAZIjP9/v TbuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=oH4q+vdPVu0G8UitJfzP9B84d+b3YQH8oJ/o88muaeU=; fh=YVpWIptA1QtmdWVQV8LkxDVZNZDhDvpOrepJDsoAZqU=; b=0oqadZ65b8+7eACeoAT4+cPtZcv6CnTK/qx+o7KcGIDEKLRymF/2vHcaF+O/kmNqm8 I6UCz0iSzkWLtYj1ZIlb56cuwzo3ghbwKjKqs/H4Qg5A5RGV1+vBThgjHhoQ8z1Fj9FZ QSBoF1unMuSPsvtX0dfZDgD1mdc41/A8b2Uhb8L33xLS41linD+IjUOdaS0ziFP19n3+ RgAyVAsbWhznQGkCsADdTGtfORuPYIt0TYpynG7axyNJMSQuUg1CpciOzhTrUFhDawZa JioYZeR/F8tURLYcbk2EXpxGtt6XCsuT0GxTZu+8xcIC6o2Ah9ppAgIFHf7+lOJLEalT pnhg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=IOfYJ16r; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x5-20020a170902820500b001a6f0e81ec7si18744279pln.237.2023.07.03.22.43.17; Mon, 03 Jul 2023 22:43:29 -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; dkim=pass header.i=@intel.com header.s=Intel header.b=IOfYJ16r; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229786AbjGDF3R (ORCPT + 99 others); Tue, 4 Jul 2023 01:29:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34890 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230301AbjGDF3F (ORCPT ); Tue, 4 Jul 2023 01:29:05 -0400 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 41B7AE52; Mon, 3 Jul 2023 22:29:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1688448544; x=1719984544; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=Oa4QuauqJ+8TcHeLgAPnDEQ9ZUhBWWVcqLElYpzmNJM=; b=IOfYJ16r2o+lJ5GatsgZSd+psAQ0uEflx/gtd2Gi8uCJbhz9W30a+k66 bxoyZSz9sF7SZZxeVXnkGaum2tZfEh9r6fLt24Qxq+8dLQUmV94oBrkoz JdIGbBulJUTurgTAT4j3kXzcxKGbs2ZuNLaxJiw/kZrS8o1kqXdBEkMQN 99dtrGlgWXxMEXmhMcJ6IAZSkoGCGtyWGsb/FRsKs+om3CXgAzQuAv7W9 VHXv+EPEcpcXjV6FjKuaD0pEUP2R2gsi5Z82XnlGFfna7YVcSx1NHdonC iYZCgJ1A8nQbE8WWO5rDhfA3RbQ/4RDDM6hbsitKQ3Vahci7tJBC2LE8T w==; X-IronPort-AV: E=McAfee;i="6600,9927,10760"; a="361899018" X-IronPort-AV: E=Sophos;i="6.01,179,1684825200"; d="scan'208";a="361899018" Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Jul 2023 22:29:03 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10760"; a="808794648" X-IronPort-AV: E=Sophos;i="6.01,179,1684825200"; d="scan'208";a="808794648" Received: from naamamex-mobl.ger.corp.intel.com (HELO [10.13.12.63]) ([10.13.12.63]) by fmsmga003-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Jul 2023 22:28:58 -0700 Message-ID: Date: Tue, 4 Jul 2023 08:28:56 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: [Intel-wired-lan] [PATCH net v2 3/6] igc: Handle already enabled taprio offload for basetime 0 Content-Language: en-US To: Florian Kauer , Jesse Brandeburg , Tony Nguyen , Vinicius Costa Gomes , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Tan Tee Min , Muhammad Husaini Zulkifli , Aravindhan Gunasekaran , Malli C Cc: netdev@vger.kernel.org, kurt@linutronix.de, intel-wired-lan@lists.osuosl.org, linux-kernel@vger.kernel.org References: <20230619100858.116286-1-florian.kauer@linutronix.de> <20230619100858.116286-4-florian.kauer@linutronix.de> From: "naamax.meir" In-Reply-To: <20230619100858.116286-4-florian.kauer@linutronix.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham 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 On 6/19/2023 13:08, Florian Kauer wrote: > Since commit e17090eb2494 ("igc: allow BaseTime 0 enrollment for Qbv") > it is possible to enable taprio offload with a basetime of 0. > However, the check if taprio offload is already enabled for i225 > (and thus -EALREADY should be returned for igc_save_qbv_schedule) > still relied on adapter->base_time > 0. > > This can be reproduced as follows: > > # TAPRIO offload (flags == 0x2) and base-time = 0 > sudo tc qdisc replace dev enp1s0 parent root handle 100 stab overhead 24 taprio \ > num_tc 1 \ > map 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 \ > queues 1@0 \ > base-time 0 \ > sched-entry S 01 300000 \ > flags 0x2 > > # The second call should fail with "Error: Device failed to setup taprio offload." > # But that only happens if base-time was != 0 > sudo tc qdisc replace dev enp1s0 parent root handle 100 stab overhead 24 taprio \ > num_tc 1 \ > map 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 \ > queues 1@0 \ > base-time 0 \ > sched-entry S 01 300000 \ > flags 0x2 > > Fixes: e17090eb2494 ("igc: allow BaseTime 0 enrollment for Qbv") > Signed-off-by: Florian Kauer > Reviewed-by: Kurt Kanzenbach > --- > drivers/net/ethernet/intel/igc/igc_main.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Tested-by: Naama Meir