From nobody Sun May 5 14:45:00 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1610936582; cv=none; d=zohomail.com; s=zohoarc; b=ckde0MYNDdy41LB6wgkRLuNsxvT37c3iRWqr2Sn0WWX4o87pfsYXtvqGAOSGKgQDW9Hm/zZ2/V5tijP11oUWd2vAQR9Rav0mD0JQyAVkbhG4I9WHCfmxbdgdmxxWahbHWOweFFI2aUf2a7OOk6P2jN2RZSxPuInFbAHKxDMrHbo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1610936582; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=DRdv5JPuZIp8cyVTrpxMbkYRhkbwHomNjweFVqrjwYw=; b=TNXCb+qakEltildtyy/tNkjymnZL852GNctdS3huhaO6wC+fPiRYH6p+dFGBgGdwlUgjOALdTx4ZAYhtULgxxkIDeytlb47fSCFxWlBJEFUkq6pF73rx/1zDjqSB/aTQGfiUN5W8Z+uyhYAfLK4mvrxbB3vispblV3bq81lRe/M= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1610936582728407.11891784359375; Sun, 17 Jan 2021 18:23:02 -0800 (PST) Received: from localhost ([::1]:49934 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l1KC5-0004tN-O6 for importer@patchew.org; Sun, 17 Jan 2021 21:23:01 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:42340) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1K8v-0002V6-W6 for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:19:46 -0500 Received: from szxga07-in.huawei.com ([45.249.212.35]:2640) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1K8t-0003Dt-J4 for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:19:45 -0500 Received: from DGGEMS407-HUB.china.huawei.com (unknown [172.30.72.59]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4DJwST6rHpz7WZp; Mon, 18 Jan 2021 10:18:33 +0800 (CST) Received: from [10.108.235.13] (10.108.235.13) by DGGEMS407-HUB.china.huawei.com (10.3.19.207) with Microsoft SMTP Server id 14.3.498.0; Mon, 18 Jan 2021 10:19:31 +0800 Subject: [PATCH V4 1/4] bsd-user: "foo * bar" should be "foo *bar" References: To: Warner Losh , Peter Maydell From: shiliyang Message-ID: <02263a65-7e3a-2d09-d7b1-6d54a19c8454@huawei.com> Date: Mon, 18 Jan 2021 10:19:31 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.108.235.13] X-CFilter-Loop: Reflected Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=45.249.212.35; envelope-from=shiliyang@huawei.com; helo=szxga07-in.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alex.chen@huawei.com, hunongda@huawei.com, QEMU Developers Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" This patch fixes error style problems found by checkpatch.pl: ERROR: "foo ** bar" should be "foo **bar". ERROR: "foo * bar" should be "foo *bar" Signed-off-by: Liyang Shi --- bsd-user/bsdload.c | 4 ++-- bsd-user/elfload.c | 16 ++++++++-------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/bsd-user/bsdload.c b/bsd-user/bsdload.c index d708a54b03..65a2346bc7 100644 --- a/bsd-user/bsdload.c +++ b/bsd-user/bsdload.c @@ -36,7 +36,7 @@ abi_long memcpy_to_target(abi_ulong dest, const void *src, return 0; } -static int count(char ** vec) +static int count(char **vec) { int i; @@ -188,7 +188,7 @@ static int find_in_path(char *path, const char *filenam= e, char *retpath, return found; } -int loader_exec(const char * filename, char ** argv, char ** envp, +int loader_exec(const char *filename, char **argv, char **envp, struct target_pt_regs *regs, struct image_info *infop, struct bsd_binprm *bprm) { diff --git a/bsd-user/elfload.c b/bsd-user/elfload.c index 373292e468..4d1a572534 100644 --- a/bsd-user/elfload.c +++ b/bsd-user/elfload.c @@ -66,12 +66,12 @@ static int load_elf_sections(const struct elfhdr *hdr, = struct elf_phdr *phdr, abi_ulong target_stksiz; abi_ulong target_stkbas; -static inline void memcpy_fromfs(void * to, const void * from, unsigned lo= ng n) +static inline void memcpy_fromfs(void *to, const void *from, unsigned long= n) { memcpy(to, from, n); } -static int load_aout_interp(void * exptr, int interp_fd); +static int load_aout_interp(void *exptr, int interp_fd); #ifdef BSWAP_NEEDED static void bswap_ehdr(struct elfhdr *ehdr) @@ -156,7 +156,7 @@ static void bswap_note(struct elf_note *en) { } * to be put directly into the top of new user memory. * */ -static abi_ulong copy_elf_strings(int argc,char ** argv, void **page, +static abi_ulong copy_elf_strings(int argc, char **argv, void **page, abi_ulong p) { char *tmp, *tmp1, *pag =3D NULL; @@ -288,7 +288,7 @@ static void padzero(abi_ulong elf_bss, abi_ulong last_b= ss) } } -static abi_ulong load_elf_interp(struct elfhdr * interp_elf_ex, +static abi_ulong load_elf_interp(struct elfhdr *interp_elf_ex, int interpreter_fd, abi_ulong *interp_load_addr) { struct elf_phdr *elf_phdata =3D NULL; @@ -614,11 +614,11 @@ int load_elf_binary(struct bsd_binprm *bprm, struct t= arget_pt_regs *regs, unsigned int interpreter_type =3D INTERPRETER_NONE; unsigned char ibcs2_interpreter; int i; - struct elf_phdr * elf_ppnt; + struct elf_phdr *elf_ppnt; struct elf_phdr *elf_phdata; abi_ulong elf_bss, elf_brk; int error, retval; - char * elf_interpreter; + char *elf_interpreter; abi_ulong baddr, elf_entry, et_dyn_addr, interp_load_addr =3D 0; abi_ulong reloc_func_desc =3D 0; char passed_fileno[6]; @@ -785,7 +785,7 @@ int load_elf_binary(struct bsd_binprm *bprm, struct tar= get_pt_regs *regs, and then start this sucker up */ { - char * passed_p; + char *passed_p; if (interpreter_type =3D=3D INTERPRETER_AOUT) { snprintf(passed_fileno, sizeof(passed_fileno), "%d", bprm->fd); @@ -2254,7 +2254,7 @@ out: #endif /* USE_ELF_CORE_DUMP */ -static int load_aout_interp(void * exptr, int interp_fd) +static int load_aout_interp(void *exptr, int interp_fd) { printf("a.out interpreter not yet supported\n"); --=20 2.29.1.59.gf9b6481aed From nobody Sun May 5 14:45:00 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1610936529; cv=none; d=zohomail.com; s=zohoarc; b=ClB/aIaB1W0/jJtS3oVC7aKZh/3ZZQfCs72FxRqd2JW1vyXH4jBkVVp/XPZ/diGdu+4TnUxno7yGsgjrDdnaAbFAHPYNKGs9d6vNBNXNtpI+w5xIhD1YHGBPgKTJl1NxUXm1NW5rPsOuH/b/4oP59jlVN1bixhWIv0O28py9qfA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1610936529; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=X3qeYU/AxrTpQQuafdTg+rYAXfW0ezi+vtzu1ygzr8I=; b=RwgesM+ZVDQlu0UN9U4+2HoFb0Rr2vsLeieTrYDvetVFHGmwTHB31/1sjFygMP4ISYqn598owbfNIl+REU1gYbhS39x0sDDYFOH/JS1E0gmcUHx6+kmdwMdjFU74+ev6ZT0QuQqYmFe8rA2amY5jLC6HARg+6KUg34pui4jTGS8= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 161093652989479.91107168421638; Sun, 17 Jan 2021 18:22:09 -0800 (PST) Received: from localhost ([::1]:47392 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l1KBE-0003sK-Lr for importer@patchew.org; Sun, 17 Jan 2021 21:22:08 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:42390) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1K9Y-0002mO-Qi for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:20:24 -0500 Received: from szxga04-in.huawei.com ([45.249.212.190]:3354) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1K9X-0003Y6-0P for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:20:24 -0500 Received: from DGGEMS413-HUB.china.huawei.com (unknown [172.30.72.59]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4DJwTF5dMWz15v7Y; Mon, 18 Jan 2021 10:19:13 +0800 (CST) Received: from [10.108.235.13] (10.108.235.13) by DGGEMS413-HUB.china.huawei.com (10.3.19.213) with Microsoft SMTP Server id 14.3.498.0; Mon, 18 Jan 2021 10:20:10 +0800 Subject: [PATCH V4 2/4] bsd-user: suspect code indent for conditional statements References: To: Warner Losh , Peter Maydell From: shiliyang Message-ID: Date: Mon, 18 Jan 2021 10:20:10 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.108.235.13] X-CFilter-Loop: Reflected Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=45.249.212.190; envelope-from=shiliyang@huawei.com; helo=szxga04-in.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alex.chen@huawei.com, hunongda@huawei.com, QEMU Developers Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" This patch fixes error style problems found by checkpatch.pl: ERROR: suspect code indent for conditional statements Signed-off-by: Liyang Shi --- bsd-user/elfload.c | 2 +- bsd-user/mmap.c | 25 +++++++++++++------------ 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/bsd-user/elfload.c b/bsd-user/elfload.c index 4d1a572534..d5cab25607 100644 --- a/bsd-user/elfload.c +++ b/bsd-user/elfload.c @@ -765,7 +765,7 @@ int load_elf_binary(struct bsd_binprm *bprm, struct tar= get_pt_regs *regs, /* Now figure out which format our binary is */ if ((N_MAGIC(interp_ex) !=3D OMAGIC) && (N_MAGIC(interp_ex) !=3D Z= MAGIC) && (N_MAGIC(interp_ex) !=3D QMAGIC)) { - interpreter_type =3D INTERPRETER_ELF; + interpreter_type =3D INTERPRETER_ELF; } if (interp_elf_ex.e_ident[0] !=3D 0x7f || diff --git a/bsd-user/mmap.c b/bsd-user/mmap.c index 1b8c8382ca..785655f319 100644 --- a/bsd-user/mmap.c +++ b/bsd-user/mmap.c @@ -487,18 +487,19 @@ abi_long target_mmap(abi_ulong start, abi_ulong len, = int prot, up to the targets page boundary. */ if ((qemu_real_host_page_size < qemu_host_page_size) && fd !=3D -1) { - struct stat sb; - - if (fstat (fd, &sb) =3D=3D -1) - goto fail; - - /* Are we trying to create a map beyond EOF?. */ - if (offset + len > sb.st_size) { - /* If so, truncate the file map at eof aligned with - the hosts real pagesize. Additional anonymous maps - will be created beyond EOF. */ - len =3D REAL_HOST_PAGE_ALIGN(sb.st_size - offset); - } + struct stat sb; + + if (fstat(fd, &sb) =3D=3D -1) { + goto fail; + } + + /* Are we trying to create a map beyond EOF?. */ + if (offset + len > sb.st_size) { + /* If so, truncate the file map at eof aligned with + the hosts real pagesize. Additional anonymous maps + will be created beyond EOF. */ + len =3D REAL_HOST_PAGE_ALIGN(sb.st_size - offset); + } } if (!(flags & MAP_FIXED)) { --=20 2.29.1.59.gf9b6481aed From nobody Sun May 5 14:45:00 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1610936605; cv=none; d=zohomail.com; s=zohoarc; b=CTQQ2XwgybawQESbfaAvVvAPHePnCZHeX+iKakr05ugc7xmpnwxdE05WNvKjMorcjX3kz7X76XeSeRb1TFhm058GhBISGuVQch3kprb5gmxSGIKx/xge2zHQHE1oXOaGc+ViVdsgeA9q4gwffgcCUt+7rmvzTnLg4daObzxOE0g= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1610936605; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=sz0BQhFz2ttarNnpisvgXXXyj9/0YSEVophBPLsr1iw=; b=YddtXDbMhkRGl52AzoAAK7KcScNpvOHo9dBObJRT9wTxRg7DQir13XOeWHxGUcioT9N82dxJZupzo/TvlKKBFW8GtR66trRvOnutOi+i6fG/VTKCD/N5v44SiLZNd/puN6yB/d3KhkN17roqeqKvkV8r/6gWth8GqKofb3Dvups= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 161093660577282.5715255458963; Sun, 17 Jan 2021 18:23:25 -0800 (PST) Received: from localhost ([::1]:51632 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l1KCS-0005ZS-P2 for importer@patchew.org; Sun, 17 Jan 2021 21:23:24 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:42434) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1KA1-0002y9-NI for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:20:53 -0500 Received: from szxga04-in.huawei.com ([45.249.212.190]:3291) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1K9z-0003j8-TC for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:20:53 -0500 Received: from DGGEMS413-HUB.china.huawei.com (unknown [172.30.72.59]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4DJwTV3z1wzl6Fv; Mon, 18 Jan 2021 10:19:26 +0800 (CST) Received: from [10.108.235.13] (10.108.235.13) by DGGEMS413-HUB.china.huawei.com (10.3.19.213) with Microsoft SMTP Server id 14.3.498.0; Mon, 18 Jan 2021 10:20:39 +0800 Subject: [PATCH V4 3/4] bsd-user: do not use C99 // comments References: To: Warner Losh , Peter Maydell From: shiliyang Message-ID: <2d69a2e7-67a2-3660-8ffe-de0962a046af@huawei.com> Date: Mon, 18 Jan 2021 10:20:39 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.108.235.13] X-CFilter-Loop: Reflected Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=45.249.212.190; envelope-from=shiliyang@huawei.com; helo=szxga04-in.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alex.chen@huawei.com, hunongda@huawei.com, QEMU Developers Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" This patch fixes error messages found by checkpatch.pl: ERROR: do not use C99 // comments Signed-off-by: Liyang Shi --- bsd-user/elfload.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bsd-user/elfload.c b/bsd-user/elfload.c index d5cab25607..2842dfe56b 100644 --- a/bsd-user/elfload.c +++ b/bsd-user/elfload.c @@ -390,7 +390,7 @@ static const char *lookup_symbolxx(struct syminfo *s, t= arget_ulong orig_addr) struct elf_sym *syms =3D s->disas_symtab.elf64; #endif - // binary search + /* binary search */ struct elf_sym *sym; sym =3D bsearch(&orig_addr, syms, s->disas_num_syms, sizeof(*syms), sy= mfind); @@ -465,7 +465,7 @@ found: i =3D 0; while (i < nsyms) { bswap_sym(syms + i); - // Throw away entries which we do not need. + /* Throw away entries which we do not need. */ if (syms[i].st_shndx =3D=3D SHN_UNDEF || syms[i].st_shndx >=3D SHN_LORESERVE || ELF_ST_TYPE(syms[i].st_info) !=3D STT_FUNC) { --=20 2.29.1.59.gf9b6481aed From nobody Sun May 5 14:45:00 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1610936639; cv=none; d=zohomail.com; s=zohoarc; b=kzNDRyS6hecMfWHVy47d+qdRSaFPqrUwzQIoElzkpJsg59As5HiqdsNILuQ0cTWnVYjV9vBSpxSvQbbWTUH3o8WB+eNgyTFkpa8piLs9gz/8RdwLFAoJCFgj+SH9OTdi0SbLw9fkMXnEQL9/OdnySq1TKkZxeH4BRTAoaSrWBnk= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1610936639; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=95T0Op84+I12iSp0Q1c7//58zYYYhVrJbCjJEgU7Xv0=; b=Kx53iDbJU5tX2ihcpx6PeQqM7W3WgdvN+bmTBrU86N4+dzkzuKFdDQJEft0/FkKU54ssfls2MBI1XbHLWJ1C9Yfux/YbMfBdsWmhRrOoWh5eXTSZuf6Bt37Q10Uiy1zRevRnF8/8oFiHnyRhWWVKKTti5sckWzZp0sGOhiMtOEo= ARC-Authentication-Results: i=1; mx.zohomail.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1610936639831486.7431351878721; Sun, 17 Jan 2021 18:23:59 -0800 (PST) Received: from localhost ([::1]:54076 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l1KD0-0006YS-Sr for importer@patchew.org; Sun, 17 Jan 2021 21:23:58 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:42542) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1KAh-0003ey-Fg for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:21:35 -0500 Received: from szxga04-in.huawei.com ([45.249.212.190]:3355) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l1KAc-0003yT-NH for qemu-devel@nongnu.org; Sun, 17 Jan 2021 21:21:35 -0500 Received: from DGGEMS407-HUB.china.huawei.com (unknown [172.30.72.59]) by szxga04-in.huawei.com (SkyGuard) with ESMTP id 4DJwVX000Pz15rk0; Mon, 18 Jan 2021 10:20:19 +0800 (CST) Received: from [10.108.235.13] (10.108.235.13) by DGGEMS407-HUB.china.huawei.com (10.3.19.207) with Microsoft SMTP Server id 14.3.498.0; Mon, 18 Jan 2021 10:21:18 +0800 Subject: [PATCH V4 4/4] bsd-user: space required after semicolon References: To: Warner Losh , Peter Maydell From: shiliyang Message-ID: <6bdfc158-0f16-b19f-4c65-8c47338f1dcc@huawei.com> Date: Mon, 18 Jan 2021 10:21:18 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.108.235.13] X-CFilter-Loop: Reflected Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=45.249.212.190; envelope-from=shiliyang@huawei.com; helo=szxga04-in.huawei.com X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: alex.chen@huawei.com, hunongda@huawei.com, QEMU Developers Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" This patch fixes error style problems found by checkpatch.pl: ERROR: space required after that ',' Signed-off-by: Liyang Shi --- bsd-user/elfload.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/bsd-user/elfload.c b/bsd-user/elfload.c index 2842dfe56b..c89c998c22 100644 --- a/bsd-user/elfload.c +++ b/bsd-user/elfload.c @@ -636,8 +636,8 @@ int load_elf_binary(struct bsd_binprm *bprm, struct tar= get_pt_regs *regs, #ifndef __FreeBSD__ bprm->p =3D copy_elf_strings(1, &bprm->filename, bprm->page, bprm->p); - bprm->p =3D copy_elf_strings(bprm->envc,bprm->envp,bprm->page,bprm->p); - bprm->p =3D copy_elf_strings(bprm->argc,bprm->argv,bprm->page,bprm->p); + bprm->p =3D copy_elf_strings(bprm->envc, bprm->envp, bprm->page, bprm-= >p); + bprm->p =3D copy_elf_strings(bprm->argc, bprm->argv, bprm->page, bprm-= >p); if (!bprm->p) { retval =3D -E2BIG; } @@ -739,7 +739,7 @@ int load_elf_binary(struct bsd_binprm *bprm, struct tar= get_pt_regs *regs, if (retval >=3D 0) { retval =3D lseek(interpreter_fd, 0, SEEK_SET); if(retval >=3D 0) { - retval =3D read(interpreter_fd,bprm->buf,128); + retval =3D read(interpreter_fd, bprm->buf, 128); } } if (retval >=3D 0) { @@ -769,7 +769,7 @@ int load_elf_binary(struct bsd_binprm *bprm, struct tar= get_pt_regs *regs, } if (interp_elf_ex.e_ident[0] !=3D 0x7f || - strncmp((char *)&interp_elf_ex.e_ident[1], "ELF",3) !=3D 0= ) { + strncmp((char *)&interp_elf_ex.e_ident[1], "ELF", 3) !=3D = 0) { interpreter_type &=3D ~INTERPRETER_ELF; } @@ -792,7 +792,7 @@ int load_elf_binary(struct bsd_binprm *bprm, struct tar= get_pt_regs *regs, passed_p =3D passed_fileno; if (elf_interpreter) { - bprm->p =3D copy_elf_strings(1,&passed_p,bprm->page,bprm->= p); + bprm->p =3D copy_elf_strings(1, &passed_p, bprm->page, bpr= m->p); bprm->argc++; } } --=20 2.29.1.59.gf9b6481aed