mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paul Bolle <pebolle@tiscali.nl>
To: Roy Pledge <Roy.Pledge@freescale.com>
Cc: linuxppc-dev@lists.ozlabs.org, scottwood@freescale.com,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 02/11] soc/fsl: Introduce DPAA BMan device management driver
Date: Fri, 10 Jul 2015 13:36:00 +0200	[thread overview]
Message-ID: <1436528160.20619.159.camel@tiscali.nl> (raw)
In-Reply-To: <1436473322-21247-3-git-send-email-Roy.Pledge@freescale.com>

On do, 2015-07-09 at 16:21 -0400, Roy Pledge wrote:
> --- /dev/null
> +++ b/drivers/soc/fsl/qbman/Kconfig

> +menuconfig FSL_DPA
> +	bool "Freescale DPAA support"
> +	depends on FSL_SOC || COMPILE_TEST

(I already commented on COMPILE_TEST in a separate mail.)

> +	default n
> +	help
> +		FSL Data-Path Acceleration Architecture drivers
> +
> +		These are not the actual Ethernet driver(s)
> +
> +if FSL_DPA
> +
> +config FSL_DPA_CHECKING
> +	bool "additional driver checking"
> +	default n
> +	help
> +		Compiles in additional checks to sanity-check the drivers and
> +		any use of it by other code. Not recommended for performance

Only recommended for people that are certain none of the 100+ asserts
will ever trigger. See below.

> +config FSL_DPA_CAN_WAIT
> +	bool
> +	default y
> +
> +config FSL_DPA_CAN_WAIT_SYNC
> +	bool
> +	default y

Both these aren't actually used in this patch. The first patch that uses
them is 3/11.

Besides, the way these two symbols are implemented makes them function
as aliases for FSL_DPA. So why are they needed?

> +config FSL_BMAN
> +	tristate "BMan device management"
> +	default n
> +	help
> +		FSL DPAA BMan driver

(Will readers know what BMan means?)

> +endif # FSL_DPA

> --- /dev/null
> +++ b/drivers/soc/fsl/qbman/Makefile

> +obj-$(CONFIG_FSL_BMAN)				+= bman.o

> --- /dev/null
> +++ b/drivers/soc/fsl/qbman/bman.c

> +int bm_pool_set(u32 bpid, const u32 *thresholds)
> +{
> +	if (!bm)
> +		return -ENODEV;
> +	bm_set_pool(bm, bpid, thresholds[0], thresholds[1],
> +		thresholds[2], thresholds[3]);
> +	return 0;
> +}
> +EXPORT_SYMBOL(bm_pool_set);

Nit: the first (caller of this function and) user of this export is
added in 3/11.

I couldn't find a MODULE_LICENSE() in bman.c. So building this as a
module and loading that module will generate a warning and taint the
kernel.

> --- /dev/null
> +++ b/drivers/soc/fsl/qbman/dpaa_sys.h

> +#ifdef CONFIG_FSL_DPA_CHECKING
> +#define DPA_ASSERT(x) \
> +	do { \
> +		if (!(x)) { \
> +			pr_crit("ASSERT: (%s:%d) %s\n", __FILE__, __LINE__, \
> +				__stringify_1(x)); \
> +			dump_stack(); \
> +			panic("assertion failure"); \

Not my call, but why panic() here?

> +		} \
> +	} while (0)
> +#else
> +#define DPA_ASSERT(x)
> +#endif

Thanks,


Paul Bolle

  parent reply	other threads:[~2015-07-10 11:36 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-09 20:21 [PATCH 00/11] Freescale DPAA QBMan Drivers Roy Pledge
2015-07-09 20:21 ` [PATCH 01/11] powerpc: re-add devm_ioremap_prot() Roy Pledge
2015-07-09 20:21 ` [PATCH 02/11] soc/fsl: Introduce DPAA BMan device management driver Roy Pledge
2015-07-10  8:38   ` Paul Bolle
2015-07-10 17:31     ` Scott Wood
2015-07-10 18:29       ` Roy Pledge
2015-07-10 18:50         ` Scott Wood
2015-07-10 11:36   ` Paul Bolle [this message]
2015-07-10 17:33     ` Scott Wood
2015-07-10 20:57       ` Roy Pledge
2015-07-10 21:12         ` Scott Wood
2015-07-09 20:21 ` [PATCH 03/11] soc/fsl: Introduce the DPAA BMan portal driver Roy Pledge
2015-07-10 13:32   ` Paul Bolle
2015-07-10 15:19     ` Roy Pledge
2015-07-10 16:47       ` Paul Bolle
2015-07-09 20:21 ` [PATCH 04/11] soc/fsl: Introduce drivers for the DPAA QMan Roy Pledge
2015-07-11 10:34   ` Paul Bolle
2015-07-09 20:21 ` [PATCH 05/11] soc/bman: Add self-tester for BMan driver Roy Pledge
2015-07-09 20:21 ` [PATCH 06/11] soc/qman: Add self-tester for QMan driver Roy Pledge
2015-07-09 20:21 ` [PATCH 07/11] soc/bman: Add debugfs support for the BMan driver Roy Pledge
2015-07-09 20:21 ` [PATCH 08/11] soc/qman: Add debugfs support for the QMan driver Roy Pledge
2015-07-09 20:22 ` [PATCH 09/11] soc/bman: Add HOTPLUG_CPU support to the BMan driver Roy Pledge
2015-07-09 20:22 ` [PATCH 10/11] soc/qman: Add HOTPLUG_CPU support to the QMan driver Roy Pledge
2015-07-09 20:22 ` [PATCH 11/11] soc/qman: add qman_delete_cgr_safe() Roy Pledge

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1436528160.20619.159.camel@tiscali.nl \
    --to=pebolle@tiscali.nl \
    --cc=Roy.Pledge@freescale.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=netdev@vger.kernel.org \
    --cc=scottwood@freescale.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®