Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp732616pxj; Thu, 17 Jun 2021 12:30:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz2qjfxID6chPQdcE/juRP4MhBCyTh+Bv3sOp1KLrhWaWCIybbIOp2zExNfhO51coBMeMru X-Received: by 2002:a05:6638:144a:: with SMTP id l10mr6210456jad.50.1623958230819; Thu, 17 Jun 2021 12:30:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623958230; cv=none; d=google.com; s=arc-20160816; b=AqWG1+YOGbOgOYfrf8YHWKcK7lQVcXxetemi1HD6wVpw3BAgYM70JLH1DmcbfM7lwO sHRWVyOOF7ANb4jIbdcUbCB8KnEnjsQbH1N7Bo7RWVOf21yU1+wa7wUdJR9udkCoGJyU sDNvlMAMvHKjXyglMtP9MLr1ybblA2ftzfSDdovGFEiGTePtl77Smweily5BL6/GLL9l /VIufLbIPQ8QMQ5kB2+Xm82+SlmaLOEbWj3ZmLVifbsOQHnlGhJ5bQBphzvsQtwx5azJ +0wLSHuXjLbM6XUaIxEP9bh3VKKs6tdeC3IqnBp9XmCMeD3hlrcVEVf6PXTY9+KefU2h tlQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id; bh=l4GY0A/Bzx3gd3rJbvw+b95zItlGNLiMZAC9wmX0FFg=; b=M+q+tan0N05NUkuFOyb6EFvk0agB3YJEXjnrBP8Sa/LCHkx1cOfeHXbMHZvXIcD3Rg Y1W7w/SVf3C3q+fc9crO5Y564mTxNQjfvLUweSkP6A/IBVyDtPtlfqCbU7bh48f059/z AFPYyoh3ci3baMlEIyRficBTSzcADsK9ZRag5knujx/rQH/+EZiE4Y4RKqVV+sDRAcjT Ndp1ndOZOJ1dXfgBhYg/zwOuQMxKnrCG2pGLFDnxvDxOYWMYLzIR8k5Ac2wAgvn9iJ8D wIkrlfKb9N/i0UfTnzQ3Nwf5p5GSzmZYE+NI7HJvLH/NEHWmNkuHoNV/vHy0CzZ2pllw JZ2g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p14si8351210ilo.118.2021.06.17.12.30.06; Thu, 17 Jun 2021 12:30:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-wireless-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231772AbhFQRZv (ORCPT + 99 others); Thu, 17 Jun 2021 13:25:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47386 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230457AbhFQRZt (ORCPT ); Thu, 17 Jun 2021 13:25:49 -0400 Received: from sipsolutions.net (s3.sipsolutions.net [IPv6:2a01:4f8:191:4433::2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6DD84C061574 for ; Thu, 17 Jun 2021 10:23:41 -0700 (PDT) Received: by sipsolutions.net with esmtpsa (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.94.2) (envelope-from ) id 1ltvjs-0089S5-E6; Thu, 17 Jun 2021 19:23:36 +0200 Message-ID: <4526c9fb8269675a98845160d15d4b746ae3b62e.camel@sipsolutions.net> Subject: Re: [RFC v1 000/256] wireless: cl8k driver for Celeno IEEE 802.11ax devices From: Johannes Berg To: viktor.barna@celeno.com, linux-wireless@vger.kernel.org Cc: Kalle Valo , "David S . Miller" , Jakub Kicinski , Aviad Brikman , Eliav Farber , Oleksandr Savchenko , Shay Bar Date: Thu, 17 Jun 2021 19:23:35 +0200 In-Reply-To: <20210617160223.160998-1-viktor.barna@celeno.com> (sfid-20210617_180250_327693_0073AC4A) References: <20210617160223.160998-1-viktor.barna@celeno.com> (sfid-20210617_180250_327693_0073AC4A) Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.38.4 (3.38.4-1.fc33) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-malware-bazaar: not-scanned Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Hi Viktor, > The RFC is divided into separate patches on a per-file basis to simplify > the review process. Wow, umm, seems big! LOC maybe not, but # of files ... not that easy to review. I've only looked a little while now, but for making this easier to review it would be nice to split it into a "minimum viable product" first, i.e. have a much smaller driver, and this is probably not an exhaustive list: * without command line interfaces with string parsing built into the kernel (OK, that's probably something that will never go upstream anyway) * Kconfig vs. code inconsistencies cleaned up, you have a TON of CONFIG_* ifdefs that don't even exist and can never be set, so remove the code, at least for now? * remove wrappers like cl_snprintf(), though that seems part of all those command line interfaces built into the driver * consider joining some of the many header files into bigger chunks, header files that are 50% boilerplate aren't really all that useful * namespace your things better - e.g. "is_ipv4_packet" and friends? (why do you even care?) * remove all vendor commands for now, and read the vendor commands upstreaming documentation before re-introducing them https://wireless.wiki.kernel.org/en/developers/documentation/nl80211#vendor-specific_api * remove utils/string.c, obviously, use kernel stuff directly or improve where needed I guess - but likely all part of the weird CLI- in-kernel stuff? * remove abstraction layers like cl_timer * what's this VNS stuff? doesn't look like it belongs into a driver (a mac80211 one at that!) * bitfields in endian-safe code are generally frowned upon, so you shouldn't need cl_are_host_bits_le(). And also cl_are_host_bits_be()? What? * Use ERR_PTR() and friends, instead of out pointer parameters. You'll probably also notice a lot of issues yourself if you take a step back and actually read your patches, rather than just the code they were generated from, e.g. the Kconfig confusion I mentioned below. Thanks, johannes