From owner-svn-src-all@freebsd.org Thu Jun 2 15:14:41 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 79EC5B64F45; Thu, 2 Jun 2016 15:14:41 +0000 (UTC) (envelope-from br@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 2D8BC108B; Thu, 2 Jun 2016 15:14:41 +0000 (UTC) (envelope-from br@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u52FEeIT034665; Thu, 2 Jun 2016 15:14:40 GMT (envelope-from br@FreeBSD.org) Received: (from br@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u52FEe21034664; Thu, 2 Jun 2016 15:14:40 GMT (envelope-from br@FreeBSD.org) Message-Id: <201606021514.u52FEe21034664@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: br set sender to br@FreeBSD.org using -f From: Ruslan Bukin Date: Thu, 2 Jun 2016 15:14:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r301205 - head/sys/riscv/riscv X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Jun 2016 15:14:41 -0000 Author: br Date: Thu Jun 2 15:14:40 2016 New Revision: 301205 URL: https://svnweb.freebsd.org/changeset/base/301205 Log: Fix typos. Modified: head/sys/riscv/riscv/elf_machdep.c Modified: head/sys/riscv/riscv/elf_machdep.c ============================================================================== --- head/sys/riscv/riscv/elf_machdep.c Thu Jun 2 14:25:10 2016 (r301204) +++ head/sys/riscv/riscv/elf_machdep.c Thu Jun 2 15:14:40 2016 (r301205) @@ -1,7 +1,7 @@ /*- * Copyright 1996-1998 John D. Polstra. * Copyright (c) 2015 Ruslan Bukin - * Copyright (c) 2016 Yukishige SHibata + * Copyright (c) 2016 Yukishige Shibata * All rights reserved. * * Portions of this software were developed by SRI International and the @@ -132,7 +132,7 @@ SYSCTL_INT(_kern, OID_AUTO, debug_kld, struct type2str_ent { int type; - const char* str; + const char *str; }; void @@ -203,28 +203,28 @@ insert_imm(uint32_t insn, uint32_t imm, } /* - * The RISCV ISA is designed so that all of immediate value is - * sign-extened. + * The RISC-V ISA is designed so that all of immediate values are + * sign-extended. * An immediate value is sometimes generated at runtime by adding * 12bit sign integer and 20bit signed integer. This requests 20bit * immediate value to be ajusted if the MSB of the 12bit immediate - * value is asserted (sign extened value is treated as negative value). + * value is asserted (sign-extended value is treated as negative value). * * For example, 0x123800 can be calculated by adding upper 20 bit of - * 0x124000 and signed-extended 12bit immediate whose bit pattern is - * 0x800 as follows; + * 0x124000 and sign-extended 12bit immediate whose bit pattern is + * 0x800 as follows: * 0x123800 * = 0x123000 + 0x800 * = (0x123000 + 0x1000) + (-0x1000 + 0x800) * = (0x123000 + 0x1000) + (0xff...ff800) - * = 0x124000 + sign-exntend(0x800) + * = 0x124000 + sign-extention(0x800) */ static uint32_t calc_hi20_imm(uint32_t value) { /* * There is the arithmetical hack that can remove conditional - * statement. But I implement it in straghtforward way. + * statement. But I implement it in straightforward way. */ if ((value & 0x800) != 0) value += 0x1000; @@ -246,7 +246,7 @@ static const struct type2str_ent t2s[] = { R_RISCV_LO12_S, "R_RISCV_LO12_S" }, }; -static const char* +static const char * reloctype_to_str(int type) { int i; @@ -373,7 +373,7 @@ elf_reloc_internal(linker_file_t lf, Elf return -1; val = addr - (Elf_Addr)where; if ((val <= -(1UL << 32) || (1UL << 32) <= val)) { - printf("kldload:%s: huge offset against R_RISCV_CALL\n"); + printf("kldload: huge offset against R_RISCV_CALL\n"); return -1; }