Received: from eggs.gnu.org ([2001:4830:134:3::10]:55571) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fqMWh-0002cX-GF for qemu-devel@nongnu.org; Thu, 16 Aug 2018 13:57:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fqMWe-0003L8-AV for qemu-devel@nongnu.org; Thu, 16 Aug 2018 13:57:39 -0400 Received: from mail-pf1-x443.google.com ([2607:f8b0:4864:20::443]:41832) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fqMWe-0003Kl-2C for qemu-devel@nongnu.org; Thu, 16 Aug 2018 13:57:36 -0400 Received: by mail-pf1-x443.google.com with SMTP id y10-v6so2348392pfn.8 for ; Thu, 16 Aug 2018 10:57:36 -0700 (PDT) References: <1534431497-1385-1-git-send-email-aleksandar.markovic@rt-rk.com> <1534431497-1385-49-git-send-email-aleksandar.markovic@rt-rk.com> From: Richard Henderson Message-ID: Date: Thu, 16 Aug 2018 10:57:32 -0700 MIME-Version: 1.0 In-Reply-To: <1534431497-1385-49-git-send-email-aleksandar.markovic@rt-rk.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v9 48/84] disas: Add support for microMIPS and nanoMIPS List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Aleksandar Markovic , qemu-devel@nongnu.org Cc: peter.maydell@linaro.org, laurent@vivier.eu, riku.voipio@iki.fi, philippe.mathieu.daude@gmail.com, aurelien@aurel32.net, amarkovic@wavecomp.com, smarkovic@wavecomp.com, pjovanovic@wavecomp.com, pburton@wavecomp.com On 08/16/2018 07:57 AM, Aleksandar Markovic wrote: > +#define umips_decode_gpr3_reg_names(rn) mips_gpr_names[umips_decode_gpr3[rn]] > +#define umips_decode_gpr3_src_store_reg_names(rn) \ > + mips_gpr_names[umips_decode_gpr3_src_store[rn]] > + > +int nanomips_dis(char *buf, unsigned address, unsigned short one, > + unsigned short two, unsigned short three); > + > +int print_insn_micromips(bfd_vma memaddr, struct disassemble_info *info) > +{ All of the umips stuff is GPLv3 code and cannot be included in QEMU. At least it corresponds quite closely to binutils commit commit df58fc944dbc6d5efd8d3826241b64b6af22f447 (HEAD) Author: Richard Sandiford Date: Sun Jul 24 14:20:15 2011 +0000 bfd/ 2011-02-25 Chao-ying Fu Ilie Garbacea Maciej W. Rozycki Joseph Myers Catherine Moore Richard Sandiford IANAL, and the GNU project has always allowed the original license holder to distribute under multiple licenses, which in this case would be mips.com, now wavecomp.com, but... ug. That said, you don't seem to actually be using *any* of the micromips bits. You've stripped all of that out from the body of print_insn_micromips and then call into nanomips_dis. So just remove all of the bits you aren't using, and rename the entry point, and you'll be fine. > new file mode 100644 > index 0000000..35c3973 > --- /dev/null > +++ b/disas/nanomips.cpp > @@ -0,0 +1,15752 @@ > + > +#include > +#include > +#include > + > +#define INCLUDE_STANDALONE_UNIT_TEST This is new code and needs a comment at the top for its license. r~