svn commit: r321983 - head/sys/dev/mlx5/mlx5_core

Hans Petter Selasky hselasky at FreeBSD.org
Thu Aug 3 09:11:53 UTC 2017


Author: hselasky
Date: Thu Aug  3 09:11:51 2017
New Revision: 321983
URL: https://svnweb.freebsd.org/changeset/base/321983

Log:
  Using GFP_ATOMIC with firmware commands is not supported after busdma was
  introduced in the mlx5core, because busdma might sleep when loading memory
  into DMA.
  
  MFC after:	3 days
  Sponsored by:	Mellanox Technologies

Modified:
  head/sys/dev/mlx5/mlx5_core/mlx5_cmd.c

Modified: head/sys/dev/mlx5/mlx5_core/mlx5_cmd.c
==============================================================================
--- head/sys/dev/mlx5/mlx5_core/mlx5_cmd.c	Thu Aug  3 08:03:22 2017	(r321982)
+++ head/sys/dev/mlx5/mlx5_core/mlx5_cmd.c	Thu Aug  3 09:11:51 2017	(r321983)
@@ -1434,12 +1434,11 @@ static int cmd_exec_helper(struct mlx5_core_dev *dev,
 	struct mlx5_cmd_msg *inb;
 	struct mlx5_cmd_msg *outb;
 	int pages_queue;
-	gfp_t gfp;
+	const gfp_t gfp = GFP_KERNEL;
 	int err;
 	u8 status = 0;
 
 	pages_queue = is_manage_pages(in);
-	gfp = callback ? GFP_ATOMIC : GFP_KERNEL;
 
 	inb = alloc_msg(dev, in_size, gfp);
 	if (IS_ERR(inb)) {


More information about the svn-src-all mailing list