From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1163242AbdAIQWV (ORCPT ); Mon, 9 Jan 2017 11:22:21 -0500 Received: from bombadil.infradead.org ([198.137.202.9]:52056 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934751AbdAIQVp (ORCPT ); Mon, 9 Jan 2017 11:21:45 -0500 Date: Mon, 9 Jan 2017 08:21:43 -0800 From: Christoph Hellwig To: Tejun Heo Cc: Geert Uytterhoeven , "linux-ide@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH] libata-eh: Use switch() instead of sparse array for protocol strings Message-ID: <20170109162143.GA11959@infradead.org> References: <1483973368-6828-1-git-send-email-geert@linux-m68k.org> <20170109152319.GA12827@mtj.duckdns.org> <20170109160424.GB12827@mtj.duckdns.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170109160424.GB12827@mtj.duckdns.org> User-Agent: Mutt/1.7.1 (2016-10-04) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jan 09, 2017 at 11:04:24AM -0500, Tejun Heo wrote: > ata_force_param_buf is __initdata and shouldn't really matter. > ata_scsi_rbuf, hmmm, idk. Maybe we can allocate it dynamically when > registering the first ATA device so that systems w/o them can avoid > the wastage. Having it global is kinda weird anyway. But looking the code none of the commands actually using is in the paging path, so it could simply be replaced with a dynamic allocation in ata_scsi_rbuf_fill for the actually needed size, which often will be very small, or sometimes even 0.