From nobody Tue Nov 11 20:53:45 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.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; Authentication-Results: mx.zohomail.com; spf=pass (zoho.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=1565355287; cv=none; d=zoho.com; s=zohoarc; b=OSZSLPkrJCTONJir4JMgzP3SQdLNaf51EDGOb8a6nLGpBAO2Rqptq8SNvYOSU1x6P2LawD+jKMF8VW/ndeBLTztcOqY/zhMDC42/271VeYpU/YR/qGGyBm2EnvSMc1HgEpBcqd1IXl7h9YeiJfrjqMT7ODeVzP4bUF6X4QWicXE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1565355287; h=Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=eydVIeZI/JpV3DMD15EQ2w/9xHGbrKfs06wNdZc0BEw=; b=fQOXJqFFh4KP0SR0nNqL2ARfg/OaOCkjZY//24hewEcszaQvNIxh7NWGQWL9lqvcPALEgbQx+rk1ufLvQPshy8Z0Mh+keZEpsDouinHl1iQtxCPG4FOeeJ/bnVE+7mCEdA5VUbx3Ukquhej/yaXMwCzwruyhyx/BrljwANuHWac= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.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 1565355287482801.7633613897066; Fri, 9 Aug 2019 05:54:47 -0700 (PDT) Received: from localhost ([::1]:59098 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hw4Pu-0005wY-F2 for importer@patchew.org; Fri, 09 Aug 2019 08:54:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52953) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hw4K0-0002GJ-J8 for qemu-devel@nongnu.org; Fri, 09 Aug 2019 08:48:44 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hw4Jz-0001Ep-E1 for qemu-devel@nongnu.org; Fri, 09 Aug 2019 08:48:40 -0400 Received: from mx2.rt-rk.com ([89.216.37.149]:52568 helo=mail.rt-rk.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hw4Jz-00019Q-65 for qemu-devel@nongnu.org; Fri, 09 Aug 2019 08:48:39 -0400 Received: from localhost (localhost [127.0.0.1]) by mail.rt-rk.com (Postfix) with ESMTP id 71E0C1A211A; Fri, 9 Aug 2019 14:48:25 +0200 (CEST) Received: from rtrkw774-lin.domain.local (rtrkw774-lin.domain.local [10.10.13.43]) by mail.rt-rk.com (Postfix) with ESMTPSA id 5231F1A1E5E; Fri, 9 Aug 2019 14:48:25 +0200 (CEST) X-Virus-Scanned: amavisd-new at rt-rk.com From: Aleksandar Markovic To: qemu-devel@nongnu.org Date: Fri, 9 Aug 2019 14:46:48 +0200 Message-Id: <1565354819-1495-16-git-send-email-aleksandar.markovic@rt-rk.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1565354819-1495-1-git-send-email-aleksandar.markovic@rt-rk.com> References: <1565354819-1495-1-git-send-email-aleksandar.markovic@rt-rk.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 89.216.37.149 Subject: [Qemu-devel] [PATCH for 4.2 v7 15/26] target/mips: Style improvements in mips_mipssim.c 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: arikalo@wavecomp.com, philmd@redhat.com, amarkovic@wavecomp.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Aleksandar Markovic Fixes mostly errors and warnings reported by 'checkpatch.pl -f'. Signed-off-by: Aleksandar Markovic --- hw/mips/mips_mipssim.c | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/hw/mips/mips_mipssim.c b/hw/mips/mips_mipssim.c index 824abda..b3155e17 100644 --- a/hw/mips/mips_mipssim.c +++ b/hw/mips/mips_mipssim.c @@ -3,7 +3,7 @@ * * Emulates a very simple machine model similar to the one used by the * proprietary MIPS emulator. - *=20 + * * Copyright (c) 2007 Thiemo Seufer * * Permission is hereby granted, free of charge, to any person obtaining a= copy @@ -75,8 +75,9 @@ static int64_t load_kernel(void) (uint64_t *)&kernel_high, big_endian, EM_MIPS, 1, 0); if (kernel_size >=3D 0) { - if ((entry & ~0x7fffffffULL) =3D=3D 0x80000000) + if ((entry & ~0x7fffffffULL) =3D=3D 0x80000000) { entry =3D (int32_t)entry; + } } else { error_report("could not load kernel '%s': %s", loaderparams.kernel_filename, @@ -88,9 +89,10 @@ static int64_t load_kernel(void) initrd_size =3D 0; initrd_offset =3D 0; if (loaderparams.initrd_filename) { - initrd_size =3D get_image_size (loaderparams.initrd_filename); + initrd_size =3D get_image_size(loaderparams.initrd_filename); if (initrd_size > 0) { - initrd_offset =3D (kernel_high + ~INITRD_PAGE_MASK) & INITRD_P= AGE_MASK; + initrd_offset =3D (kernel_high + ~INITRD_PAGE_MASK) & + INITRD_PAGE_MASK; if (initrd_offset + initrd_size > loaderparams.ram_size) { error_report("memory too small for initial ram disk '%s'", loaderparams.initrd_filename); @@ -174,8 +176,9 @@ mips_mipssim_init(MachineState *machine) /* Map the BIOS / boot exception handler. */ memory_region_add_subregion(address_space_mem, 0x1fc00000LL, bios); /* Load a BIOS / boot exception handler image. */ - if (bios_name =3D=3D NULL) + if (bios_name =3D=3D NULL) { bios_name =3D BIOS_FILENAME; + } filename =3D qemu_find_file(QEMU_FILE_TYPE_BIOS, bios_name); if (filename) { bios_size =3D load_image_targphys(filename, 0x1fc00000LL, BIOS_SIZ= E); @@ -211,8 +214,10 @@ mips_mipssim_init(MachineState *machine) get_system_io(), 0, 0x00010000); memory_region_add_subregion(get_system_memory(), 0x1fd00000, isa); =20 - /* A single 16450 sits at offset 0x3f8. It is attached to - MIPS CPU INT2, which is interrupt 4. */ + /* + * A single 16450 sits at offset 0x3f8. It is attached to + * MIPS CPU INT2, which is interrupt 4. + */ if (serial_hd(0)) serial_init(0x3f8, env->irq[4], 115200, serial_hd(0), get_system_io()); --=20 2.7.4