View fanctl.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
============================================================================ | |
Name : fanctl.c | |
Author : hev <r@hev.cc> | |
Copyright : Copyright (c) 2023 hev | |
Description : CPU Fan control for 3C5000+7A2000 | |
============================================================================ | |
*/ | |
#include <fcntl.h> |
View cow-huge.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
============================================================================ | |
Name : cow-huge.c | |
Author : hev <r@hev.cc> | |
Copyright : Copyright (c) 2022 hev | |
Description : COW testcase for Huge pages | |
============================================================================ | |
*/ | |
#include <stdio.h> |
View shmem-fallocate.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/mm/shmem.c b/mm/shmem.c | |
index e4c9e5c7081f..1fb3f69e19e2 100644 | |
--- a/mm/shmem.c | |
+++ b/mm/shmem.c | |
@@ -959,11 +959,13 @@ static void shmem_undo_range(struct inode *inode, loff_t lstart, loff_t lend, | |
folio = shmem_get_partial_folio(inode, lstart >> PAGE_SHIFT); | |
if (folio) { | |
same_folio = lend < folio_pos(folio) + folio_size(folio); | |
- folio_mark_dirty(folio); | |
- if (!truncate_inode_partial_folio(folio, lstart, lend)) { |
View atomic-mark-bench.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
============================================================================ | |
Name : atomic-mark-bench.c | |
Author : Rui Wang <wangrui@loongson.cn> | |
Copyright : Copyright (c) 2022 hev | |
Description : Atomic mark benchmark | |
============================================================================ | |
*/ | |
#include <stdio.h> |
View atomic-flip-bit-bench.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
============================================================================ | |
Name : atomic-flip-bit-bench.c | |
Author : Rui Wang <wangrui@loongson.cn> | |
Copyright : Copyright (c) 2022 hev | |
Description : Atomic flip bit benchmark | |
============================================================================ | |
*/ | |
#include <stdio.h> |
View crossbuild-openssl.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
if [ ! -d openssl ]; then | |
git clone -b OpenSSL_1_1_1q https://github.com/openssl/openssl | |
fi | |
pushd openssl |
View timetctxsw.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright (C) 2010 Benoit Sigoure | |
// Copyright (C) 2022 hev | |
// | |
// This program is free software: you can redistribute it and/or modify | |
// it under the terms of the GNU General Public License as published by | |
// the Free Software Foundation, either version 3 of the License, or | |
// (at your option) any later version. | |
// | |
// This program is distributed in the hope that it will be useful, | |
// but WITHOUT ANY WARRANTY; without even the implied warranty of |
View grub-serial.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/grub-core/term/efi/serial.c b/grub-core/term/efi/serial.c | |
index 4c94723..0caa724 100644 | |
--- a/grub-core/term/efi/serial.c | |
+++ b/grub-core/term/efi/serial.c | |
@@ -65,20 +65,52 @@ do_real_config (struct grub_serial_port *port) | |
port->configured = 1; | |
} | |
+#define SERIAL_BASE 0x800000001fe001e0ul | |
+ |
View nftables.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/nft -f | |
# vim:set ts=2 sw=2 et: | |
table inet mangle | |
delete table inet mangle | |
table inet mangle { | |
set byp4 { | |
type ipv4_addr | |
flags interval |
View portmap.c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
============================================================================ | |
Name : portmap.c | |
Author : hev <r@hev.cc> | |
Copyright : Copyright (c) 2021 xyz | |
Description : TCP port mapping | |
============================================================================ | |
*/ | |
#include <errno.h> |
NewerOlder