Posts
4534
Following
316
Followers
479
Linux kernel hacker and maintainer etc.

OpenPGP: 3AB05486C7752FE1

Free Software Foundation

Protect developer freedom. Abolish software patents. Learn why software patents are unjust by checking out the new design of our initiative. https://u.fsf.org/3f-

0
1
1
@gregkh @conor OK, fair enough. Project was basing on v5.19 so it was easiest to start with that. I've tried it recently with the recent kernels and it works just fine. Since it is not nearly as complicated as e.g. SGX is, I just maintain my tree up until Keystone is a stable extension.
1
0
0

Jarkko Sakkinen

debugging issue with #SBI. i’m a newbie on this so just found out that you can inject traces with sbi_printf(). not sure but i guess you also have to have CONFIG_HVC_RISCV_SBI=y set in #kernel? #linux #riscv #sbi

0
0
0
@neil for me a misbehaving raspberry is an asset for kernel qa :-) 3B+ with broken trustzone, can put your own workloads there
0
0
1
@conor ... and thus it is a non-issue for me if this cannot go to e.g. staging. The priority is to get the Keystone project use a kernel patch instead of OOT driver. While at it, it really does not hurt to ask from @gregkh if this can be picked to staging but not a thing thah I'm go to do today or tomorrow. Still because this works on standard hardware, it *does* make sense for Linux *at some point* (and open source firmware extension).

Seems much less difficult exercise than the one I had with Intel SGX in the past...
1
0
0
@conor Generally for any TEE using it as a module has zero real world applications.
1
0
0

Jarkko Sakkinen

Edited 1 year ago
@conor I would like to also point out that Keystone driver is better to be a subsystem in vmlinux because it offers broader scope of applications than e.g. SGX or SEV-SNP, i.e. kernel could run payloads there and thus other subsystems could find use for it. For instance, we could possibly have backend for trusted keys and stuff like that. But for now either my korg tree or staging at most are the most appropriate...
1
0
0
@conor yeah, I mean for staging afaik the main requirement is that there is someone keeping the driver up to date but otherwise it is not that conservative. so feels like a good location at this point.
1
0
0
@conor yeah, the honest truth is that I just place it somewhere :-) i think the appropriate place if anywhere in the mainline would drivers/staging for the moment.
1
0
0
@conor it is highly CPU architecture dependent feature and any TEE must be part of the boot flow so I don't think it should linkable as module at all. As part of the boot flow any possible in-kernel use cases are enabled, i.e. other subsystems could have Keystone backend. Thus, I think it is best pick for now.
1
0
0

Jarkko Sakkinen

Edited 1 year ago

I can request riscv-keystone@vger.kernel.org if there is broader interest on this work.

@monsieuricon

0
0
0

Jarkko Sakkinen

Edited 1 year ago

I’ve opened up #development #git tree for in-kernel #Keystone #enclave #driver:

https://git.kernel.org/pub/scm/linux/kernel/git/jarkko/linux-riscv-keystone.git/

Existing branches:

  • keystone: follows Linus’ tree.
  • keystone-5.19.y: I’m actively trying to get Genesys2 FPGA hosting CVA6 working with this kernel version. Buddy allocator works but the use of dma_alloc_coherent() to allocate contiguous physical memory for enclaves freezes the system when it is being used (not in the call itself).

Keystone enclaves are applications hosted by Keystone security monitor running inside #OpenSBI, and partitioned and protected by physical memory protection (usually shortened as PMP) machine registers.

PMP is part of standard RISC-V ISA, which means that Keystone enclaves are usable with any RISC-V CPU with MMU. There is nothing that would prevent this coming eventually a mainline feature because it works for without non-standard or proprietary components involved.

Another favorable element of having Keystone enclaves as kernel feature is that Keystones enclave can run both in U-mode and S-mode meaning that kernel subsystems could use the feature too (if wanted). For instance, #Intel #SGX can host only ring-3 enclaves, which limits its scope.

#linux #kernel #riscv #cva6

2
0
2
@rjzak have impossible week with work but i'll check as soon as i have time, lot's unexpected stuff apologies
1
0
1

Jarkko Sakkinen

The only #diagram tool that I've ever liked was #xfig and I would still use over anything else available if it was brought to modern day.
0
0
0

Jarkko Sakkinen

#sublime #merge, software that I'm happy that I've paid for. There's some pretty decent fee options such as #Gitg from #Gnome but this has just tiny bit of extra comfort and performance (UI has very low-
latency).
0
0
0

Jarkko Sakkinen

Wrote myself a cheat sheet on how to get #unprivileged #Nix up and running because had forgotten how to do it. I like my Nix this way, i.e. a #container tool for me that actually makes sense to me I guess, and fits for my needs.

https://publish.obsidian.md/jarkko/Nix+Home+Manager

0
1
2
@rjzak busy day today but i'll look up tomorrow at some point
1
0
0
@rjzak I was pointing out the channel so that I can help over there. Just was saying what for the channel was originally created.
1
0
0

Jarkko Sakkinen

#Bitwig hack: you can get audio feedback path inside grid with "Long Delay" and "Mixer" devices.. Apparently Long Delay device can be routed back to an input of a Mixer device. Without it or with any other device this seems to not be possible.
0
0
1
@rjzak oh ok. I have IRC channel with David Howells called #linux-security at OFTC. We have mainly to sync with the Linux keyring but it is a public channel. Probably would be just easier to dig through this because it is not exactly a "yes/no" question, right?
1
0
0
Show older