Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755270Ab0D2DaW (ORCPT ); Wed, 28 Apr 2010 23:30:22 -0400 Received: from mail-px0-f174.google.com ([209.85.212.174]:59208 "EHLO mail-px0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752272Ab0D2DaT (ORCPT ); Wed, 28 Apr 2010 23:30:19 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=rE6LQeppZulnPhLlFXTkK4BSDmyBrA8eKAaB7CQG3zEw4gN219ZuFUFEM7K6uDuebX jmUXMJsYiQZWB9EWrGjNNfId4GtLxttqAjBrXSMlEmeSqvajyRpdG14xL04ch7qdnNlD sWnFfY7Xj7Vw0qhkZquEnNNYz4qBPgdCuzoWg= MIME-Version: 1.0 In-Reply-To: <20100427120516.c18b3bbb.akpm@linux-foundation.org> References: <90b950fc1003252024i5ba8989bg95f0a81e8e5e708e@mail.gmail.com> <20100330160257.e5f978a9.akpm@linux-foundation.org> <90b950fc1003301941r69dc5ce1ida64b590646049a7@mail.gmail.com> <20100330195501.747515e9.akpm@linux-foundation.org> <20100427120516.c18b3bbb.akpm@linux-foundation.org> Date: Thu, 29 Apr 2010 12:30:17 +0900 Message-ID: Subject: Re: [PATCH] added S6E63M0 AMOLED LCD Panel driver. From: InKi Dae To: Andrew Morton Cc: Pavel Machek , linux-fbdev-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org, kyungmin.park@samsung.com Content-Type: multipart/mixed; boundary=000e0cd1a588e2847b048557be7d Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 5965 Lines: 118 --000e0cd1a588e2847b048557be7d Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable I'm sorry for being late. this is second patch that your concern is solved. Please review this patch. Thank you. Best Regards, InKi Dae. 2010/4/28 Andrew Morton : > On Tue, 30 Mar 2010 19:55:01 -0400 > Andrew Morton wrote: > >> On Wed, 31 Mar 2010 11:41:54 +0900 InKi Dae wrote: >> >> > Hi Andrew, >> > >> > all the calls to s6e63m0_panel_send_sequence() would return -EINVAL. >> > by api_async() of driver/spi/spi.c >> >> No, spi_async() does >> >> =A0 =A0 =A0 master->transfer(spi, message); >> >> which can return at least EIO, EINPROGRESS, EINVAL or ETIMEDOUT. >> >> > so I think that those return values aren't changed to other. >> > >> > and final step is to check only whether the return value is 0 or not. >> > if you still think that this code has minor problem or you want it to >> > be corrected >> > then I will patch this code to be corrected anytime. >> >> It's a bug. >> >> Also s6e63m0_power_on() is sloppy. =A0It again or's together disparate >> errnos. =A0Then if _anything_ failed it returns hardwired -EIO, but it >> should instead propagate the callee's errno back up to the caller. >> >> And s6e63m0_power_on() can return -EFAULT in several places, which is >> nonsensical. >> >> None of this is very critical, just ... sloppy. >> > > ping? > --000e0cd1a588e2847b048557be7d Content-Type: application/octet-stream; name="s6e63m0_second.patch" Content-Disposition: attachment; filename="s6e63m0_second.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_g8l0m1m60 ZGlmZiAtLWdpdCBhL2RyaXZlcnMvdmlkZW8vYmFja2xpZ2h0L3M2ZTYzbTAuYyBiL2RyaXZlcnMv dmlkZW8vYmFja2xpZ2h0L3M2ZTYzbTAuYwppbmRleCBlNDc5M2RmLi4yNTRhMDk5IDEwMDY0NAot LS0gYS9kcml2ZXJzL3ZpZGVvL2JhY2tsaWdodC9zNmU2M20wLmMKKysrIGIvZHJpdmVycy92aWRl by9iYWNrbGlnaHQvczZlNjNtMC5jCkBAIC00MjAsMTMgKzQyMCwyNSBAQCBzdGF0aWMgaW50IF9z NmU2M20wX2dhbW1hX2N0bChzdHJ1Y3QgczZlNjNtMCAqbGNkLCBjb25zdCB1bnNpZ25lZCBpbnQg KmdhbW1hKQogCiAJLyogZGlzYWJsZSBnYW1tYSB0YWJsZSB1cGRhdGluZy4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Qg fD0gczZlNjNtMF9nYW1tYV9jdGwobGNkLCBiZC0+cHJvcHMuYnJpZ2h0bmVzcyk7CisJcmV0ID0g czZlNjNtMF9nYW1tYV9jdGwobGNkLCBiZC0+cHJvcHMuYnJpZ2h0bmVzcyk7CiAJaWYgKHJldCkg ewogCQlkZXZfZXJyKGxjZC0+ZGV2LCAibGNkIGdhbW1hIHNldHRpbmcgZmFpbGVkLlxuIik7Ci0J CXJldHVybiAtRUlPOworCQlyZXR1cm4gcmV0OwogCX0KIAogCXJldHVybiAwOwo= --000e0cd1a588e2847b048557be7d-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/