From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966086AbdDTRgI (ORCPT ); Thu, 20 Apr 2017 13:36:08 -0400 Received: from mail-io0-f195.google.com ([209.85.223.195]:33845 "EHLO mail-io0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964933AbdDTRgF (ORCPT ); Thu, 20 Apr 2017 13:36:05 -0400 Date: Thu, 20 Apr 2017 10:36:03 -0700 From: Myungho Jung To: Thomas Gleixner Cc: linux-kernel@vger.kernel.org Subject: Re: [PATCH] timer: fix timer_migration to accept only 0 and 1 Message-ID: <20170420173603.GA7780@fqdn.specialj.com> References: <1492640690-3550-1-git-send-email-mhjungk@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 20, 2017 at 02:53:26PM +0200, Thomas Gleixner wrote: > On Wed, 19 Apr 2017, Myungho Jung wrote: > > > Error is not shown by setting invalid value to timer_migration. Valid > > values for timer_migration should be restricted to 0 and 1. Testcase for > > this bug is ltp/runpwtests06. > > While I agree with the change, I disagree with the changelog. Where is the bug? > > The timer code checks for timer_migration != 0 resp. == 0. So as long as > the value is != 0 it's enabled, if it's 0 it is disabled. > > It's a correctness issue that we treat a sysctl which is basically a > boolean as such. Ideally we'd have: proc_doboolvec() for such cases and > convert all similar sysctls over to that. > > Thanks, > > tglx I understood. I'll resubmit the patch after fixing log. Thanks, Myungho