From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9561D45FD9; Fri, 3 Jan 2025 20:04:51 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 82DF3402B4; Fri, 3 Jan 2025 20:04:51 +0100 (CET) Received: from mail-pl1-f171.google.com (mail-pl1-f171.google.com [209.85.214.171]) by mails.dpdk.org (Postfix) with ESMTP id 23DAD4021E for ; Fri, 3 Jan 2025 20:04:50 +0100 (CET) Received: by mail-pl1-f171.google.com with SMTP id d9443c01a7336-2161eb94cceso123753215ad.2 for ; Fri, 03 Jan 2025 11:04:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1735931089; x=1736535889; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=E/yG/g8vY5dgf91LnkTwzAjrzrC2+UwjAasJiijCEBw=; b=pagGZ+DqR40OElQGPdpa0wUsv23aSThQe3MNEmhBDghlfumuSqeHiFHI5uvNB0EpMx FoP4gbH8Zk68T3rwIHVDOJvo8l4axQS+NvuYQlnFOuhxCpuIsnRJb2GCIVuCOp3+lvJe ymu60Ov+9cvBinYQ0erfiT1klR4sJXF09K98Aygim6AlzQGkC4zOL377qCYWi2uno0rk TZfBxHvFYFDmlZCG04CDiEVjJISNYq21NdOdn3bjcjdp8929ot61MenwebVdZjZlBkdM oBJ1qBoAfHm8VQsk9Qmk1lVA4qrL+g4hXSExXUsk6Wqe0eaBgFtqb8XrbLDVARybS90j tpwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1735931089; x=1736535889; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=E/yG/g8vY5dgf91LnkTwzAjrzrC2+UwjAasJiijCEBw=; b=nyX7mkijAgLjWQnn/Yj4kJR56i56hLyAvcI5MsZVNA5PeZAkilL+JhscJFN508ybuD ETd/zpC00ORvlb6agoHiAonOSv9/Mg9zLOBmt8NTsP0byX4eFlSAdN0+L6DWk9FxukpV pEGjO6fbIzvIiqAOl9MAw34jjyJH8TvokNlmDyufsJq44GPWIzmMY6SuhJM2SpEdwKKa Fw20rCgCMiw8gr1MsztMaFSHVl7XBUy2n331TWuRDY6F1CgtohK/hdoEZ3nCJEWGgd1N wDpxmwgrbelDCizfntfyRGMeshMkBja+n2E+qWm0+DLjnlkAKHiWvqeE1H7sb/CL9OXJ XhYQ== X-Gm-Message-State: AOJu0YyuEUtchWVYFjNyzwsdflC5FMiTk6mUVjDqm4H4w/KkujTFWDvh +NhUryjXL6BT+jrsUmB+rX8ZzXpZxBP0JA2s/S1iLDFFm6b6A1CRXEDwEGZ49Fk= X-Gm-Gg: ASbGnctMaVtVl7h4T1LxBmlnuT4YJjGRhquX2Vvgsepbyv8D8Ys9fZaQR/i8HTnWG6P raSbJ+ncV3ipmsYBdZu8fUonRI6+lEZvZzLsZBFCX5WX/4gOeBDMeaKug0ijmQ6kbETpXp/g13T bsbzr5XfxrEdEyUWn+zI0UajgNPyjvbenTJQbYESeeKvYo08ym9ccIegBGRb+9w2KryipJDf3pL LLeYY47rcFseLs83sx8MBrXGSjqeNqFd8VTqIJJwTNAcOpVyQ3H2mbl5hGTfWL0nPL0DZWJ+iY2 3e6vRFr/ X-Google-Smtp-Source: AGHT+IHAuUaN9PBmbZqZbJnAu5dJMgl0kiQJWWug9ec5B6y3ccMnS8CiVh9jo6fLSIIZ46bT8ngzTg== X-Received: by 2002:a05:6a20:7fa2:b0:1e0:d1c3:97d1 with SMTP id adf61e73a8af0-1e5e080294cmr79464089637.29.1735931089343; Fri, 03 Jan 2025 11:04:49 -0800 (PST) Received: from pi5 (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-72aad90c18fsm27650178b3a.184.2025.01.03.11.04.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Jan 2025 11:04:49 -0800 (PST) Date: Fri, 3 Jan 2025 11:04:46 -0800 From: Stephen Hemminger To: "WanRenyong" Cc: , , , , , , , , , Subject: Re: [PATCH v4 04/15] net/xsc: add xsc dev ops to support VFIO driver Message-ID: <20250103110446.08fcc408@pi5> In-Reply-To: <20250103150411.1529663-5-wanry@yunsilicon.com> References: <20250103150404.1529663-1-wanry@yunsilicon.com> <20250103150411.1529663-5-wanry@yunsilicon.com> X-Mailer: Claws Mail 4.1.1 (GTK 3.24.38; aarch64-unknown-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Fri, 03 Jan 2025 23:04:13 +0800 "WanRenyong" wrote: > +static int > +xsc_vfio_set_mtu(struct xsc_dev *xdev, uint16_t mtu) > +{ > + struct xsc_cmd_set_mtu_mbox_in in; > + struct xsc_cmd_set_mtu_mbox_out out; > + int ret; > + > + memset(&in, 0, sizeof(in)); > + memset(&out, 0, sizeof(out)); Optionally, you can initalize on stack variables with: struct xsc_cmd_set_mtu_mbox_in in = { }; Either way is ok, it is up to you.