lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 20 Feb 2014 20:30:57 +0400
From:	Alexey Perevalov <a.perevalov@...sung.com>
To:	Thomas Gleixner <tglx@...utronix.de>
Cc:	linux-kernel@...r.kernel.org, john.stultz@...aro.org,
	Anton Vorontsov <anton@...msg.org>, anton@...sg.org,
	kyungmin.park@...sung.com, cw00.choi@...sung.com,
	akpm@...ux-foundation.org,
	Anton Vorontsov <anton.vorontsov@...aro.org>
Subject: Re: [PATCH v3 4/6] timerfd: Factor out timer-type unspecific
 timerfd_expire()

On 02/20/2014 02:52 PM, Thomas Gleixner wrote:
> On Thu, 20 Feb 2014, Alexey Perevalov wrote:
>
>> From: Anton Vorontsov <anton@...msg.org>
>>
>> There is nothing hrtimer-specific inside the timerfd_tmrproc(), except
>> the function prototype. We're about to add other timer types, so factor
>> out generic timerfd_expire() helper from timerfd_tmrproc().
> This changelog is completely useless. How is timerfd_tmrproc, which is
> not a function but a function pointer, related to the patch?
>
> Moving duplicated code to a common function is nice, but ....
>   
>> Signed-off-by: Anton Vorontsov <anton.vorontsov@...aro.org>
>> Signed-off-by: Alexey Perevalov <a.perevalov@...sung.com>
>> ---
>>   fs/timerfd.c |   40 +++++++++++++++++++---------------------
>>   1 file changed, 19 insertions(+), 21 deletions(-)
>>
>> diff --git a/fs/timerfd.c b/fs/timerfd.c
>> index 9293121..3561ce7 100644
>> --- a/fs/timerfd.c
>> +++ b/fs/timerfd.c
>> @@ -229,6 +229,23 @@ static unsigned int timerfd_poll(struct file *file, poll_table *wait)
>>   	return events;
>>   }
>>   
>> +static u64 timerfd_rearm(struct timerfd_ctx *ctx)
>> +{
>> +	u64 orun;
>> +
>> +	if (isalarm(ctx)) {
>> +		orun += alarm_forward_now(
>> +			&ctx->t.alarm, ctx->tintv) - 1;
>> +		alarm_restart(&ctx->t.alarm);
>> +	} else {
>> +		orun += hrtimer_forward_now(&ctx->t.tmr,
>> +		     ctx->tintv) - 1;
>> +		hrtimer_restart(&ctx->t.tmr);
> Warnings are there to be ignored and testing of user space
> interfaces after a change is overrated, right?
>
> Aside of that you just blindly copied the original code w/o fixing up
> the now unnecessary line breaks.
>
> The summary of this patch is:
>
>      1) Breaks existing functionality including user space ABI
>      2) Compiler warnings ignored
>      3) Untested
>      4) Utter lack of programming style
>      5) Useless changelog
>
> Impressive for a trivial thing like this.
>
> Thanks,
>
> 	tglx
>
Compiler warning - if you mean uninitialized orun, I fixed it
ill-timed in the next patch,
yes it should be in original patch.

-- 
Best regards,
Alexey Perevalov
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ