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] [day] [month] [year] [list]
Message-id: <52776BD5.7080607@samsung.com>
Date:	Mon, 04 Nov 2013 18:41:41 +0900
From:	Chanwoo Choi <cw00.choi@...sung.com>
To:	Charles Keepax <ckeepax@...nsource.wolfsonmicro.com>
Cc:	myungjoo.ham@...sung.com, patches@...nsource.wolfsonmicro.com,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 1/2] extcon: arizona: Fix reset of HPDET after race with
 removal

On 11/04/2013 06:21 PM, Charles Keepax wrote:
> On Mon, Nov 04, 2013 at 09:32:50AM +0900, Chanwoo Choi wrote:
>> The arizona_hpdet_do_id() return only either -EAGIN or 0(zero).
>> extcon-arizona driver could never execute 'goto done;' statement.
>>
>> 	ret = arizona_hpdet_do_id(info, &reading, &mic);
>> 	if (ret == -EAGAIN) {
>> 		goto out;
>> 	} else if (ret < 0) {
>> 		goto done;
>> 	}
> 
> True that else if is redundant at the moment, but personally I
> would be inclined to leave it in, it feels safer against possible
> future edits of arizona_hpdet_do_id. It would be reasonable for
> someone to assume that other return values are acceptable whilst
> editing it but they would then not be handled.

I know your intention. But, I cannot apply this patch for potential issue.
Also, we have to fix below dead code after returning arizona_hpdet_do_id()

	>> 	} else if (ret < 0) {
	>> 		goto done;
	>> 	}


Thanks,
Chanwoo Choi

--
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