From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753217AbbCNIow (ORCPT ); Sat, 14 Mar 2015 04:44:52 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:34989 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750788AbbCNIoq (ORCPT ); Sat, 14 Mar 2015 04:44:46 -0400 Date: Sat, 14 Mar 2015 09:44:42 +0100 From: Greg KH To: Mark Hounschell Cc: Giedrius =?utf-8?Q?Statkevi=C4=8Dius?= , lidza.louina@gmail.com, devel@driverdev.osuosl.org, driverdev-devel@linuxdriverproject.org, linux-kernel@vger.kernel.org, dan.carpenter@oracle.com Subject: Re: [PATCH v2] dgnc: Don't save boards in memory that have failed to initialize Message-ID: <20150314084442.GA17298@kroah.com> References: <1425918578-10223-1-git-send-email-giedrius.statkevicius@gmail.com> <20150312100849.GA16122@kroah.com> <5501BB57.70606@gmail.com> <55034EDB.1060506@compro.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <55034EDB.1060506@compro.net> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 13, 2015 at 04:55:55PM -0400, Mark Hounschell wrote: > On 03/12/2015 12:14 PM, Giedrius Statkevičius wrote: > >On 2015.03.12 12:08, Greg KH wrote: > >>On Mon, Mar 09, 2015 at 06:29:38PM +0200, Giedrius Statkevičius wrote: > >>>Remove BOARD_FAILED and don't save dgnc_boards which failed to > >>>initialize. > >>> > >>>Assign the result of kzalloc() to brd in dgnc_found_board() and only put > >>>it in the dgnc_Board[] if it successfully initializes. Also, remove > >>>BOARD_FAILED enum and all ifs that check for it. Finally, remove one > >>>final place where state was set to BOARD_FAILED which was even redundant > >>>before this patch. > >>> > >>>Signed-off-by: Giedrius Statkevičius > >>>--- > >>>v2: Remove "brd = dgnc_Board[dgnc_NumBoards];" line which I forgot to do > >>>in the first version > >>> > >>> drivers/staging/dgnc/dgnc_driver.c | 20 ++------------------ > >>> drivers/staging/dgnc/dgnc_driver.h | 3 +-- > >>> drivers/staging/dgnc/dgnc_mgmt.c | 5 +---- > >>> drivers/staging/dgnc/dgnc_tty.c | 8 -------- > >>> 4 files changed, 4 insertions(+), 32 deletions(-) > >>> > >>>diff --git a/drivers/staging/dgnc/dgnc_driver.c b/drivers/staging/dgnc/dgnc_driver.c > >>>index fa1ee79..075727d 100644 > >>>--- a/drivers/staging/dgnc/dgnc_driver.c > >>>+++ b/drivers/staging/dgnc/dgnc_driver.c > >>>@@ -401,8 +401,7 @@ static int dgnc_found_board(struct pci_dev *pdev, int id) > >>> unsigned long flags; > >>> > >>> /* get the board structure and prep it */ > >>>- dgnc_Board[dgnc_NumBoards] = kzalloc(sizeof(*brd), GFP_KERNEL); > >>>- brd = dgnc_Board[dgnc_NumBoards]; > >>>+ brd = kzalloc(sizeof(*brd), GFP_KERNEL); > >> > >>You've done a great job here, but... > >> > >>Yeah, sorry... > >> > >>I really want to see this whole "static list of boards/cards" go away. > >>There should not be any need for that in any in-kernel driver. Your > >>patch here is a sign that things are really wrong with this whole static > >>array mess. > >> > >>So could you do that instead? I don't want to take patches around this > >>whole "board state" mess anymore, as it should all not be needed at all. > >> > >>If you need pointers on what needs to be done here, just let me know. > >> > >>thanks, > >> > >>greg k-h > >> > > > >I can try :) But my main concern is the lack of dgnc driver maintainers > >activity and that I don't own the hardware this driver is written for as > >it's quite expensive (cheapest cards I've found start at 300$~) and I > >can't afford it ATM. But I guess if I keep the patches small and logical > >everything will be okay. > > > > I am on the maintainers list and actually have hardware. I have just been so > swamped the last few months that I haven't been able to do ANYTHING here. > Even work on the dgap driver that I was working on, I just haven't had the > time. I can tell you that the dgnc driver does NOT work at all and hasn't > worked since it was introduced into staging by Greg. Really? It's always been broken? Why don't we just delete the thing? > Greg, while I'm here, how can we get Digi firmware into the kernel firmware > tree? The dgap card is useless without it and I suspect the dgnc is as well. Submit a patch to the linux-firmware git tree with the firmware in it. thanks, greg k-h