Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753962AbbELUgD (ORCPT ); Tue, 12 May 2015 16:36:03 -0400 Received: from mail-ig0-f169.google.com ([209.85.213.169]:38054 "EHLO mail-ig0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751771AbbELUf7 (ORCPT ); Tue, 12 May 2015 16:35:59 -0400 MIME-Version: 1.0 In-Reply-To: <1431455457-25322-4-git-send-email-mcgrof@do-not-panic.com> References: <1431455457-25322-1-git-send-email-mcgrof@do-not-panic.com> <1431455457-25322-4-git-send-email-mcgrof@do-not-panic.com> Date: Tue, 12 May 2015 13:35:59 -0700 X-Google-Sender-Auth: bt29X9-3YOpzRlbjcuUrahVNry8 Message-ID: Subject: Re: [PATCH v2 3/5] firmware: check for possible file truncation early From: Linus Torvalds To: "Luis R. Rodriguez" Cc: Ming Lei , Rusty Russell , David Howells , Seth Forshee , Linux Kernel Mailing List , Paul Bolle , Linux Wireless List , "Luis R. Rodriguez" , Kyle McMartin Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1059 Lines: 27 On Tue, May 12, 2015 at 11:30 AM, Luis R. Rodriguez wrote: > > Instead of waiting until the last second to fail > on a request_firmware*() calls due to filename > truncation we can do an early check upon boot > and immediatley avoid any possible issues upfront. Why? This looks stupid. Why add this special case, when normal path lookup results in the proper errors? And if invalid pathnames are so frequent that this special case is somehow worth it, we should fix whoever generates that crap, instead of adding this insane special case. And if we don't handle the errors from normal path lookup properly, then we should fix *that*. In other words, I see absolutely no reason for this patch. Regardless of the reason for it, it seems entirely broken. Linus -- 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/