Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp536843ybe; Wed, 4 Sep 2019 03:58:19 -0700 (PDT) X-Google-Smtp-Source: APXvYqwNsY4h0WkbKu2gr5SG9JB/N4PRCYDRV3FQtNLqV/EMHENmULyLtw53UBzaYKoOBFZwPDTw X-Received: by 2002:a63:841:: with SMTP id 62mr31627118pgi.1.1567594699338; Wed, 04 Sep 2019 03:58:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567594699; cv=none; d=google.com; s=arc-20160816; b=orKYyV1z/Mk8Eo3En3WVXZZJOhY56Lff68gdt2V2GQ4cLZaIzPcY7EOOZrFb9A8LGw luk6EugWxKIA/38Jb1Wyyjl99KBgAwx9FreyxR8Hcb59xnuJV/REufSg+Q3Twpb28GNU kRkbRjaxjUsKstaHEWsQukNgjLqh6PYnt3L/cTNxDOwKRejRURv1fPcJCUhUbgnpiWFs OA5x22LlvhP0rkfZsVVpvQk6YptWT0lcid546Hm2ixWGWcbQpsS7FpOw3BDytcPXN5zS esI52COVQzYBBP/xBrK8afxgl4q4d15Po9PYo0Ul4BsBezQubZezLYzF/GIEyK74sT52 77Vg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=SWfa14r8fb7+QJ7HbMqdwljQW3LaQCfzEEAIRJA/UBA=; b=zwsTdqczm5disID2zSen6uo+eph+C4bck9tZtcS42B4ptDfEx+WkkrMUYtwHWARAna 9Q568Q3d2mD7mq+D2dagPpw5BTPJu8FrbiIzWyewZgvJI2t5kET7+uE+A1wE7Zdl8AtQ 5LtxV7C6Jn7DbIEjo0K7SfU1+FrQPcmDetMCgJP6BOF0GVW2j+osOt1EavmtfFqzC0nZ KMvI89fjkDv4kzM3fS3eG7VVMo8FHy5uPj9ueM7ar/lMtmYBHZ5XSALejAzmtmUrS6UU HDhgF/B3MrsmiBd8vB40SQ8eZS31Dgk6qZvCFjNvAQWPd4t0OUYe4CAh7BziCDBDYtDx OC/w== ARC-Authentication-Results: i=1; mx.google.com; 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 e5si17261665pgl.536.2019.09.04.03.58.03; Wed, 04 Sep 2019 03:58:19 -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; 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 S1729763AbfIDKzh (ORCPT + 99 others); Wed, 4 Sep 2019 06:55:37 -0400 Received: from foss.arm.com ([217.140.110.172]:51884 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727768AbfIDKzh (ORCPT ); Wed, 4 Sep 2019 06:55:37 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 6473C337; Wed, 4 Sep 2019 03:55:36 -0700 (PDT) Received: from [192.168.0.8] (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D94B23F246; Wed, 4 Sep 2019 03:55:34 -0700 (PDT) Subject: Re: [PATCH v3] sched/core: Fix uclamp ABI bug, clean up and robustify sched_read_attr() ABI logic and code To: Ingo Molnar Cc: Thadeu Lima de Souza Cascardo , linux-kernel@vger.kernel.org, Peter Zijlstra , Ingo Molnar , Patrick Bellasi , Thomas Gleixner , Arnaldo Carvalho de Melo , Linus Torvalds , Jiri Olsa References: <20190903171645.28090-1-cascardo@canonical.com> <20190903171645.28090-2-cascardo@canonical.com> <20190904075532.GA26751@gmail.com> <20190904084934.GA117671@gmail.com> <20190904085519.GA127156@gmail.com> <20190904103925.GA60962@gmail.com> From: Dietmar Eggemann Message-ID: <43e9f6ae-7ebc-d3d8-eecf-860cdef7fdec@arm.com> Date: Wed, 4 Sep 2019 12:55:33 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <20190904103925.GA60962@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/09/2019 12:39, Ingo Molnar wrote: > > * Dietmar Eggemann wrote: > >>> -v3 attached. Build and minimally boot tested. >>> >>> Thanks, >>> >>> Ingo >>> >> >> This patch fixes the issue (almost). >> >> LTP's sched_getattr01 passes again. But IMHO the prio 'chrt -p $$' >> should be 0 instead of -65536. > > Yeah, I forgot to zero-initialize the structure ... > > Does the attached -v4 work any better for you? Yeah, looks better now. # chrt -p $$ [ 258.245786] sched_attr_copy_to_user(): copied 48 bytes. (ksize: 56, usize: 48) pid 1635's current scheduling policy: SCHED_OTHER pid 1635's current scheduling priority: 0 w/o the extra printk: Tested-by: Dietmar Eggemann