aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2021-09-24 11:29:48 +0200
committerHelge Deller <deller@gmx.de>2021-09-24 11:29:48 +0200
commitf1de5fcd6432c5d08755072516fb207876c80e9f (patch)
treedacc3216b04270b4fb72e05a09d3a266747c2049
parentdd5666df16f84f28ca55cab2785260802a9a3e20 (diff)
downloadseabios-hppa-f1de5fcd6432c5d08755072516fb207876c80e9f.zip
seabios-hppa-f1de5fcd6432c5d08755072516fb207876c80e9f.tar.gz
seabios-hppa-f1de5fcd6432c5d08755072516fb207876c80e9f.tar.bz2
parisc: Add sha256.c sha512.c and ror() function
Needed to cope with upstream changes. Signed-off-by: Helge Deller <deller@gmx.de>
-rw-r--r--Makefile.parisc2
-rw-r--r--src/parisc/hppa.h5
2 files changed, 6 insertions, 1 deletions
diff --git a/Makefile.parisc b/Makefile.parisc
index af4bb8e..4af49b6 100644
--- a/Makefile.parisc
+++ b/Makefile.parisc
@@ -38,7 +38,7 @@ SRCBOTH=output.c string.c block.c cdrom.c disk.c kbd.c \
hw/usb-hid.c hw/usb-msc.c hw/usb-uas.c \
hw/blockcmd.c hw/floppy.c hw/ata.c hw/ramdisk.c \
hw/lsi-scsi.c hw/esp-scsi.c hw/megasas.c hw/mpt-scsi.c \
- parisc/timer.c
+ parisc/timer.c sha256.c sha512.c
# x86.c fw/smp.c fw/mttr.c malloc.c
SRC32FLAT=$(SRCBOTH) post.c e820map.c romfile.c optionroms.c \
pmm.c font.c boot.c bootsplash.c jpeg.c bmp.c tcgbios.c sha1.c \
diff --git a/src/parisc/hppa.h b/src/parisc/hppa.h
index fa1b907..ca81a43 100644
--- a/src/parisc/hppa.h
+++ b/src/parisc/hppa.h
@@ -192,6 +192,11 @@ static inline u32 rol(u32 val, u16 rol) {
return res;
}
+static inline u32 ror(u32 word, unsigned int shift)
+{
+ return (word >> (shift & 31)) | (word << ((-shift) & 31));
+}
+
#define pci_ioport_addr(port) ((port >= 0x1000) && (port < FIRMWARE_START))
static inline void outl(u32 value, portaddr_t port) {