Browse Source

rebase patchset to latest HEAD

Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
Rebecca Chang Swee Fun 1 year ago
parent
commit
7aa8e9da6e

+ 12 - 12
0001-linux-sysroot-script-to-create-riscv-sysroot-from-De.patch

@@ -1,7 +1,7 @@
-From 89e1e2acf8c1c57d5f833b60a5f40a9b89440e51 Mon Sep 17 00:00:00 2001
+From ceef9e02d5fd787605d0babc94570ca41d8f7a2e Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Wed, 18 May 2022 06:00:28 +0000
-Subject: [PATCH 01/23] linux: sysroot: script to create riscv sysroot from
+Subject: [PATCH 01/21] linux: sysroot: script to create riscv sysroot from
  Debian ports
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
@@ -434,7 +434,7 @@ index 0000000000000..f8c01b96256d5
 +
 +. "${SCRIPT_DIR}/sysroot-creator.sh"
 diff --git a/build/linux/sysroot_scripts/sysroot-creator.sh b/build/linux/sysroot_scripts/sysroot-creator.sh
-index bde29db92ba02..b252c28a166a4 100644
+index fb854cbfa4d6b..c46edc8224465 100644
 --- a/build/linux/sysroot_scripts/sysroot-creator.sh
 +++ b/build/linux/sysroot_scripts/sysroot-creator.sh
 @@ -51,6 +51,7 @@ readonly HAS_ARCH_ARM64=${HAS_ARCH_ARM64:=0}
@@ -474,7 +474,7 @@ index bde29db92ba02..b252c28a166a4 100644
  StripChecksumsFromPackageList() {
    local package_file="$1"
    sed -i 's/ [a-f0-9]\{64\}$//' "$package_file"
-@@ -402,13 +411,11 @@ HacksAndPatchesAmd64() {
+@@ -407,13 +416,11 @@ HacksAndPatchesAmd64() {
    ReversionGlibc x86_64 linux-gnu
  }
  
@@ -488,7 +488,7 @@ index bde29db92ba02..b252c28a166a4 100644
  HacksAndPatchesARM() {
    HacksAndPatchesCommon arm linux-gnueabihf arm-linux-gnueabihf-strip
    ReversionGlibc arm linux-gnueabihf
-@@ -433,12 +440,15 @@ HacksAndPatchesMips() {
+@@ -438,12 +445,15 @@ HacksAndPatchesMips() {
    ReversionGlibc mipsel linux-gnu
  }
  
@@ -505,7 +505,7 @@ index bde29db92ba02..b252c28a166a4 100644
  
  InstallIntoSysroot() {
    Banner "Install Libs And Headers Into Jail"
-@@ -489,7 +499,7 @@ CleanupJailSymlinks() {
+@@ -494,7 +504,7 @@ CleanupJailSymlinks() {
    cd ${INSTALL_ROOT}
    local libdirs="lib usr/lib"
    if [ "${ARCH}" != "MIPS" ]; then
@@ -514,7 +514,7 @@ index bde29db92ba02..b252c28a166a4 100644
    fi
  
    find $libdirs -type l -printf '%p %l\n' | while read link target; do
-@@ -532,6 +542,7 @@ VerifyLibraryDepsCommon() {
+@@ -537,6 +547,7 @@ VerifyLibraryDepsCommon() {
    local all_libs="$(find ${find_dirs[*]} -printf '%f\n')"
    # Ignore missing libdbus-1.so.0
    all_libs+="$(echo -e '\nlibdbus-1.so.0')"
@@ -522,7 +522,7 @@ index bde29db92ba02..b252c28a166a4 100644
    local missing_libs="$(grep -vFxf <(echo "${all_libs}") \
      <(echo "${needed_libs}"))"
    if [ ! -z "${missing_libs}" ]; then
-@@ -546,17 +557,14 @@ VerifyLibraryDepsAmd64() {
+@@ -551,17 +562,14 @@ VerifyLibraryDepsAmd64() {
    VerifyLibraryDepsCommon x86_64 linux-gnu
  }
  
@@ -540,7 +540,7 @@ index bde29db92ba02..b252c28a166a4 100644
  VerifyLibraryDepsARM64() {
    VerifyLibraryDepsCommon aarch64 linux-gnu
  }
-@@ -569,11 +577,14 @@ VerifyLibraryDepsMips() {
+@@ -574,11 +582,14 @@ VerifyLibraryDepsMips() {
    VerifyLibraryDepsCommon mipsel linux-gnu
  }
  
@@ -556,7 +556,7 @@ index bde29db92ba02..b252c28a166a4 100644
  
  #@
  #@ BuildSysrootAmd64
-@@ -715,6 +726,26 @@ BuildSysrootMips64el() {
+@@ -720,6 +731,26 @@ BuildSysrootMips64el() {
    CreateTarBall
  }
  
@@ -583,7 +583,7 @@ index bde29db92ba02..b252c28a166a4 100644
  #@
  #@ BuildSysrootAll
  #@
-@@ -890,7 +921,7 @@ GeneratePackageList() {
+@@ -895,7 +926,7 @@ GeneratePackageList() {
    local failed=0
    for pkg in $@ ; do
      local pkg_full=$(grep -A 1 " ${pkg}\$" "$input_file" | \
@@ -592,7 +592,7 @@ index bde29db92ba02..b252c28a166a4 100644
      if [ -z "${pkg_full}" ]; then
        echo "ERROR: missing package: $pkg"
        local failed=1
-@@ -937,6 +968,9 @@ PrintArchitectures() {
+@@ -942,6 +973,9 @@ PrintArchitectures() {
    if [ "$HAS_ARCH_MIPS64EL" = "1" ]; then
      echo Mips64el
    fi

+ 2 - 2
0002-sandbox-add-riscv-arch-definition-and-define-syscall.patch

@@ -1,7 +1,7 @@
-From 04f0043bacafe896df0633fd6450a3b751399fcc Mon Sep 17 00:00:00 2001
+From b607596fa6128fd4052a187075f7d1c91ac06f8f Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Wed, 30 Mar 2022 06:38:26 +0000
-Subject: [PATCH 02/23] sandbox: add riscv arch definition and define syscall
+Subject: [PATCH 02/21] sandbox: add riscv arch definition and define syscall
  header
 
 Credit to work contributed in Github.

+ 2 - 2
0003-sandbox-linux-pass-fPIE-to-compiler.patch

@@ -1,7 +1,7 @@
-From 8f7c059991efa63ee7037a91427aab1235ec627f Mon Sep 17 00:00:00 2001
+From 0724b7c6e4ac612d183aaace97bd5c2ae0296da9 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Thu, 13 Jan 2022 03:50:24 +0000
-Subject: [PATCH 03/23] sandbox: linux: pass -fPIE to compiler
+Subject: [PATCH 03/21] sandbox: linux: pass -fPIE to compiler
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 2 - 2
0004-skia-add-riscv64.patch

@@ -1,7 +1,7 @@
-From 47d5b9768c18033ff740de7e2c072b247bfe2852 Mon Sep 17 00:00:00 2001
+From 3eaf67ac02abe0244bbcd85e362c19919f458631 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Fri, 14 Jan 2022 01:04:19 +0000
-Subject: [PATCH 04/23] skia: add riscv64
+Subject: [PATCH 04/21] skia: add riscv64
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 4 - 4
0005-base-allocator-partition_allocator-add-riscv64-suppo.patch

@@ -1,7 +1,7 @@
-From 3a0f884a18211957feb88fd6ee650c75051e3c8e Mon Sep 17 00:00:00 2001
+From 562b84239679c524a687d6fe51b4f15d87665415 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Tue, 5 Apr 2022 02:22:48 +0000
-Subject: [PATCH 05/23] base: allocator: partition_allocator: add riscv64
+Subject: [PATCH 05/21] base: allocator: partition_allocator: add riscv64
  support
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
@@ -12,10 +12,10 @@ Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
  create mode 100644 base/allocator/partition_allocator/starscan/stack/asm/riscv64/push_registers_asm.cc
 
 diff --git a/base/allocator/partition_allocator/BUILD.gn b/base/allocator/partition_allocator/BUILD.gn
-index d8272085d9676..262a57bcbc209 100644
+index 0aa0c78692c0c..68814667eee52 100644
 --- a/base/allocator/partition_allocator/BUILD.gn
 +++ b/base/allocator/partition_allocator/BUILD.gn
-@@ -225,6 +225,9 @@ target(partition_alloc_target_type, "partition_alloc") {
+@@ -268,6 +268,9 @@ target(partition_alloc_target_type, "partition_alloc") {
    } else if (current_cpu == "arm64") {
      defines += [ "PA_PCSCAN_STACK_SUPPORTED" ]
      sources += [ "starscan/stack/asm/arm64/push_registers_asm.cc" ]

+ 2 - 2
0006-base-process-add-riscv64-arch-definition.patch

@@ -1,7 +1,7 @@
-From 87a9190952f0cd3b47d55c37e6125a95028aa4a1 Mon Sep 17 00:00:00 2001
+From c6c9e34871fb5cefebd72b2a213471f766582aa8 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Tue, 10 May 2022 02:21:16 +0000
-Subject: [PATCH 06/23] base: process: add riscv64 arch definition
+Subject: [PATCH 06/21] base: process: add riscv64 arch definition
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 3 - 3
0007-remoting-fix-missing-cstring-header.patch

@@ -1,7 +1,7 @@
-From 583d891f4642244c5249065bdde985aa9940d4f0 Mon Sep 17 00:00:00 2001
+From d4acfec99e4386a9fe985fc565bd49cc5c368f14 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Thu, 13 Jan 2022 09:44:47 +0000
-Subject: [PATCH 07/23] remoting: fix missing cstring header
+Subject: [PATCH 07/21] remoting: fix missing cstring header
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---
@@ -13,7 +13,7 @@ Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
  5 files changed, 5 insertions(+), 4 deletions(-)
 
 diff --git a/remoting/base/util.cc b/remoting/base/util.cc
-index 20eedfb3a34cb..4c1fdcc75ca7d 100644
+index df36b1b8ee848..b80da87b4f558 100644
 --- a/remoting/base/util.cc
 +++ b/remoting/base/util.cc
 @@ -3,7 +3,7 @@

+ 2 - 2
0008-remoting-codec-fix-missing-cmath-header.patch

@@ -1,7 +1,7 @@
-From 5a9eff06278e30dd09775f4cbed32c2c693bd9c5 Mon Sep 17 00:00:00 2001
+From 2930864be17f9be1b3b8634f04b9e93297af8841 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Thu, 13 Jan 2022 09:48:12 +0000
-Subject: [PATCH 08/23] remoting: codec: fix missing cmath header
+Subject: [PATCH 08/21] remoting: codec: fix missing cmath header
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 2 - 2
0009-components-update_client-add-riscv64-arch-definition.patch

@@ -1,7 +1,7 @@
-From b919c1f1a31b647ef3f5f124c22f5ee0b5950f08 Mon Sep 17 00:00:00 2001
+From e7cc091068534e90a7c3b4077b2bf04c6b93a7c4 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Tue, 5 Apr 2022 02:27:27 +0000
-Subject: [PATCH 09/23] components: update_client: add riscv64 arch definition
+Subject: [PATCH 09/21] components: update_client: add riscv64 arch definition
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 3 - 3
0010-build-config-compiler-use_gold-linker-option.patch

@@ -1,7 +1,7 @@
-From 75e05df5b897b869e57063d14d1035ad5b258f78 Mon Sep 17 00:00:00 2001
+From 5905f914424bd3d88fc3f13f3162c09041ac3827 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Mon, 17 Jan 2022 04:48:24 +0000
-Subject: [PATCH 10/23] build: config: compiler: use_gold linker option
+Subject: [PATCH 10/21] build: config: compiler: use_gold linker option
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---
@@ -9,7 +9,7 @@ Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/build/config/compiler/compiler.gni b/build/config/compiler/compiler.gni
-index 0567598343ea6..f5080708c9483 100644
+index 36108aaf7a091..3b8732d8b4c40 100644
 --- a/build/config/compiler/compiler.gni
 +++ b/build/config/compiler/compiler.gni
 @@ -223,7 +223,7 @@ declare_args() {

+ 4 - 4
0011-build-config-compiler-remove-flags-not-available-in-.patch

@@ -1,7 +1,7 @@
-From 1cce24d3de450d4ea65b66886f64b3a769d119d3 Mon Sep 17 00:00:00 2001
+From 33b1085723465d61aff44f41229061d047235eda Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Mon, 17 Jan 2022 08:15:52 +0000
-Subject: [PATCH 11/23] build: config: compiler: remove flags not available in
+Subject: [PATCH 11/21] build: config: compiler: remove flags not available in
  custom clang
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
@@ -10,7 +10,7 @@ Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
  1 file changed, 13 deletions(-)
 
 diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
-index c90821ecde179..79710a677bcfe 100644
+index df8610696cc6e..c9b6fb9c83114 100644
 --- a/build/config/compiler/BUILD.gn
 +++ b/build/config/compiler/BUILD.gn
 @@ -345,7 +345,6 @@ config("compiler") {
@@ -50,7 +50,7 @@ index c90821ecde179..79710a677bcfe 100644
      }
    }
  
-@@ -749,10 +740,6 @@ config("compiler") {
+@@ -755,10 +746,6 @@ config("compiler") {
    if (use_lld && !enable_call_graph_profile_sort) {
      if (is_win) {
        ldflags += [ "/call-graph-profile-sort:no" ]

+ 3 - 3
0012-build-config-add-atomic-build-flag.patch

@@ -1,7 +1,7 @@
-From d20f32720eac124195f162317c8187ce0670f21d Mon Sep 17 00:00:00 2001
+From 469d52902d6995983352b93a8e0f2d98f739f03a Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Wed, 30 Mar 2022 05:43:35 +0000
-Subject: [PATCH 12/23] build: config: add atomic build flag
+Subject: [PATCH 12/21] build: config: add atomic build flag
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---
@@ -9,7 +9,7 @@ Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
  1 file changed, 1 insertion(+)
 
 diff --git a/build/config/BUILD.gn b/build/config/BUILD.gn
-index 79f1b1aebe9a5..627b01b3c9859 100644
+index 392733e36defc..562e66ede051a 100644
 --- a/build/config/BUILD.gn
 +++ b/build/config/BUILD.gn
 @@ -223,6 +223,7 @@ config("default_libs") {

+ 23 - 7
0013-build-config-compiler-set-generic-riscv64-flags.patch

@@ -1,30 +1,46 @@
-From 34419d06a338f38be840773b44c049e694146962 Mon Sep 17 00:00:00 2001
+From a42e058e178f7993351b30a928ac4e464eb16aa9 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Fri, 14 Jan 2022 05:06:56 +0000
-Subject: [PATCH 13/23] build: config: compiler: set generic riscv64 flags
+Subject: [PATCH 13/21] build: config: compiler: set generic riscv64 flags
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
+Signed-off-by: Loh Tien Hock <tienhock.loh@starfivetech.com>
 ---
- build/config/compiler/BUILD.gn | 6 ++++++
- 1 file changed, 6 insertions(+)
+ build/config/compiler/BUILD.gn | 14 +++++++++++++-
+ 1 file changed, 13 insertions(+), 1 deletion(-)
 
 diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
-index 79710a677bcfe..429943e426ef3 100644
+index c9b6fb9c83114..43043a135afa7 100644
 --- a/build/config/compiler/BUILD.gn
 +++ b/build/config/compiler/BUILD.gn
-@@ -1152,6 +1152,12 @@ config("compiler_cpu_abi") {
+@@ -1158,6 +1158,17 @@ config("compiler_cpu_abi") {
          cflags += [ "-m64" ]
          ldflags += [ "-m64" ]
        }
 +    } else if (current_cpu == "riscv64") {
 +      cflags += [
 +        "-m64",
-+        "-march=rv64gc",
++        "--target=riscv64-linux-gnu",
++        "-mno-relax",
 +        "-mabi=lp64d",
++      ]
++      ldflags += [
++        "--target=riscv64-linux-gnu",
++        "-mno-relax",
 +      ]
      } else if (current_cpu == "s390x") {
        cflags += [ "-m64" ]
        ldflags += [ "-m64" ]
+@@ -1626,7 +1637,8 @@ config("chromium_code") {
+ 
+     if (!is_debug && !using_sanitizer && current_cpu != "s390x" &&
+         current_cpu != "s390" && current_cpu != "ppc64" &&
+-        current_cpu != "mips" && current_cpu != "mips64") {
++        current_cpu != "mips" && current_cpu != "mips64" &&
++        current_cpu != "riscv64") {
+       # Non-chromium code is not guaranteed to compile cleanly with
+       # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are
+       # disabled, so only do that for Release build.
 -- 
 2.25.1
 

+ 2 - 2
0014-chrome-common-remove-unrar-code.patch

@@ -1,7 +1,7 @@
-From 796fe4577f25873b97485b430b1fd17d72d4fcea Mon Sep 17 00:00:00 2001
+From f30ae7596f0cfc6ccda8b1eb286526223b0d9271 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Thu, 13 Jan 2022 08:57:34 +0000
-Subject: [PATCH 14/23] chrome: common: remove unrar code
+Subject: [PATCH 14/21] chrome: common: remove unrar code
 
 Upstream-status: Inappropriate
 

+ 2 - 2
0015-third_party-libaom-add-riscv-target.patch

@@ -1,7 +1,7 @@
-From 7c1c6ca12315892184dcdc154e0f1254dbf7b062 Mon Sep 17 00:00:00 2001
+From b696f43d6dcd36827dad04e38e49d4f90335b178 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Wed, 30 Mar 2022 11:24:25 +0000
-Subject: [PATCH 15/23] third_party: libaom: add riscv target
+Subject: [PATCH 15/21] third_party: libaom: add riscv target
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 2 - 2
0016-third_party-libvpx-add-riscv-target.patch

@@ -1,7 +1,7 @@
-From 81299de9e6388b34a00e8731dab6b5081a3b2214 Mon Sep 17 00:00:00 2001
+From 9aab974f2c32f2771a002c36c1d0ca1854521588 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Wed, 30 Mar 2022 11:26:18 +0000
-Subject: [PATCH 16/23] third_party: libvpx: add riscv target
+Subject: [PATCH 16/21] third_party: libvpx: add riscv target
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 4 - 4
0017-third_party-crashpad-add-support-for-riscv.patch

@@ -1,7 +1,7 @@
-From 62457fa5271a6b22210ec0adefe6fee944f785f7 Mon Sep 17 00:00:00 2001
+From 57fb23b78c06744d5e7c688d6716bcbff4b48e55 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Thu, 31 Mar 2022 00:35:10 +0000
-Subject: [PATCH 17/23] third_party: crashpad: add support for riscv
+Subject: [PATCH 17/21] third_party: crashpad: add support for riscv
 
 Credit to work contributed in Github.
 https://github.com/felixonmars/archriscv-packages/tree/master/chromium
@@ -77,7 +77,7 @@ index c10743d84899d..616b43654d11f 100644
  
  #endif  // CRASHPAD_MINIDUMP_MINIDUMP_CONTEXT_H_
 diff --git a/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc b/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
-index 6ae25b8fe12f8..cfd86fa9f4d58 100644
+index bf02c1bd28926..796c8b5383613 100644
 --- a/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
 +++ b/third_party/crashpad/crashpad/minidump/minidump_context_writer.cc
 @@ -102,6 +102,13 @@ MinidumpContextWriter::CreateFromSnapshot(const CPUContext* context_snapshot) {
@@ -94,7 +94,7 @@ index 6ae25b8fe12f8..cfd86fa9f4d58 100644
      default: {
        LOG(ERROR) << "unknown context architecture "
                   << context_snapshot->architecture;
-@@ -557,4 +564,41 @@ size_t MinidumpContextMIPS64Writer::ContextSize() const {
+@@ -556,4 +563,41 @@ size_t MinidumpContextMIPS64Writer::ContextSize() const {
    return sizeof(context_);
  }
  

+ 2 - 2
0018-third_party-lzma_sdk-add-riscv-arch-definition.patch

@@ -1,7 +1,7 @@
-From bdd1bde72c2c366d2e2a3effc6ddabb2db714f28 Mon Sep 17 00:00:00 2001
+From 7aace00cb0decea066c70ddc4f51a873ef734ae2 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Fri, 14 Jan 2022 05:07:31 +0000
-Subject: [PATCH 18/23] third_party: lzma_sdk: add riscv arch definition
+Subject: [PATCH 18/21] third_party: lzma_sdk: add riscv arch definition
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 2 - 2
0019-build-linux-sysroot-create-a-sysroot-for-riscv.patch

@@ -1,7 +1,7 @@
-From 5254439289bd00f5fb9269f3abfa3625c4c80040 Mon Sep 17 00:00:00 2001
+From c0d3509f68c1fd87bf107283ad7a24e8249f6a10 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Tue, 5 Apr 2022 06:40:16 +0000
-Subject: [PATCH 19/23] build: linux: sysroot: create a sysroot for riscv
+Subject: [PATCH 19/21] build: linux: sysroot: create a sysroot for riscv
 
 Upstream-status: Unidentified
 

+ 3 - 3
0020-workaround-for-files-not-found-in-sysroot.patch

@@ -1,7 +1,7 @@
-From 69881d81443cd78aa9aca83ffc15298325ab9bdc Mon Sep 17 00:00:00 2001
+From dd931268ba165d00de11163a50d5acd80085a202 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Thu, 28 Apr 2022 01:03:56 +0000
-Subject: [PATCH 20/23] workaround for files not found in sysroot
+Subject: [PATCH 20/21] workaround for files not found in sysroot
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---
@@ -9,7 +9,7 @@ Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
  1 file changed, 4 insertions(+), 1 deletion(-)
 
 diff --git a/buildtools/third_party/libc++/BUILD.gn b/buildtools/third_party/libc++/BUILD.gn
-index 74b6ad644d49c..cf7ad5b2f8426 100644
+index b3e5378f711c5..b54980669c194 100644
 --- a/buildtools/third_party/libc++/BUILD.gn
 +++ b/buildtools/third_party/libc++/BUILD.gn
 @@ -23,7 +23,10 @@ config("config") {

+ 2 - 2
0021-v8-settings.patch

@@ -1,7 +1,7 @@
-From 6ca882e4e194fdddac7c66bc2dee2907093a3796 Mon Sep 17 00:00:00 2001
+From f3fc8ee028d27beee7a7b5b57e408c0671b6e857 Mon Sep 17 00:00:00 2001
 From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 Date: Thu, 28 Apr 2022 01:04:27 +0000
-Subject: [PATCH 21/23] v8 settings
+Subject: [PATCH 21/21] v8 settings
 
 Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
 ---

+ 0 - 35
0022-compiler-workaround.patch

@@ -1,35 +0,0 @@
-From 00827741648ebd7d5f98e5f9fd718ad2f7435785 Mon Sep 17 00:00:00 2001
-From: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
-Date: Thu, 28 Apr 2022 01:04:59 +0000
-Subject: [PATCH 22/23] compiler workaround
-
-Signed-off-by: Rebecca Chang Swee Fun <rebecca.chang@starfivetech.com>
----
- build/config/compiler/BUILD.gn | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn
-index 429943e426ef3..0ccc0035434f3 100644
---- a/build/config/compiler/BUILD.gn
-+++ b/build/config/compiler/BUILD.gn
-@@ -1154,6 +1154,7 @@ config("compiler_cpu_abi") {
-       }
-     } else if (current_cpu == "riscv64") {
-       cflags += [
-+        "--target=riscv64-linux-gnu",
-         "-m64",
-         "-march=rv64gc",
-         "-mabi=lp64d",
-@@ -1627,7 +1628,8 @@ config("chromium_code") {
- 
-     if (!is_debug && !using_sanitizer && current_cpu != "s390x" &&
-         current_cpu != "s390" && current_cpu != "ppc64" &&
--        current_cpu != "mips" && current_cpu != "mips64") {
-+        current_cpu != "mips" && current_cpu != "mips64" &&
-+        current_cpu != "riscv64") {
-       # Non-chromium code is not guaranteed to compile cleanly with
-       # _FORTIFY_SOURCE. Also, fortified build may fail when optimizations are
-       # disabled, so only do that for Release build.
--- 
-2.25.1
-