jailhouse enable in x86 Broke affinity for irq 125, smpboot: CPU 3 is now offline

2018-10-23 Thread Ashok kumar
Hi,

after enable jailhouse

sudo tools/jailhouse enable configs/x86/sysconfig.cell

in syslog the following message is I get


texsonics kernel: [  174.219041]  The Jailhouse is opening.
Oct 22 18:01:01 texsonics kernel: [  244.918968] Broke affinity for irq 125
Oct 22 18:01:01 texsonics kernel: [  244.920002] smpboot: CPU 3 is now
offline

Is it correct

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


x86 architecture system hangs on sudo tools/jailhouse cell destroy apic-demo, Broke affinity for irq 125, smpboot: CPU 3 is now offline

2018-10-22 Thread Ashok kumar
Hi,


I am using x86 i3 core processor

I have added
 void vcpu_park(void)
 {
 #ifdef CONFIG_CRASH_CELL_ON_PANIC
-   if (this_cpu_data()->failed) {
+   if (this_cpu_public()->failed) {
this_cpu_data()->vmcb.rip = 0;
return;
}

 void vcpu_park(void)
 {
 #ifdef CONFIG_CRASH_CELL_ON_PANIC
-   if (this_cpu_data()->failed) {
+   if (this_cpu_public()->failed) {
vmcs_write64(GUEST_RIP, 0);
return;
}


in the corresponding files arch/hypervisor/arch/x86/vmx.c
  arch/hypervisor/arch/x86/svm.c
and after executing  command

sudo tools/jailhouse enable configs/x86/sysconfig.cell

in syslog the following message is I get


texsonics kernel: [  174.219041]  The Jailhouse is opening.
Oct 22 18:01:01 texsonics kernel: [  244.918968] Broke affinity for irq 125
Oct 22 18:01:01 texsonics kernel: [  244.920002] smpboot: CPU 3 is now
offline

sudo tools/jailhouse cell create configs/x86/apic-demo.cell

smpboot: CPU 3 is now offline
Oct 22 18:01:01 texsonics kernel: [  244.947989] Created Jailhouse cell
"apic-demo"
Oct 22 18:01:03 texsonics /usr/sbin/irqbalance: WARNING, didn't collect
load info for all cpus, balancing is broken
Oct 22 18:02:43 texsonics /usr/sbin/irqbalance: message repeated 16 times:
[ WARNING, didn't collect load info for all cpus, balancing is broken]
Oct 22 18:02:53 texsonics /usr/sbin/irqbalance: WARNING, didn't collect
load info for all cpus, balancing is broken

sudo tools/jailhouse cell destroy apic-demo

smpboot: Booting Node 0 Processor 3 APIC 0x3
Oct 22 18:05:04 texsonics kernel: [  488.138877] Destroyed Jailhouse cell
"apic-demo"

and my system gets hangs and in my UART  I get

Stopped APIC demo
Closing cell "apic-demo"
Page pool usage after cell destruction mem 295/15823, remap 16394/131072
cpu 3 received SIPI,vector 97

kindly help me to solve this issue, so that I should able to destroy
jailhouse cell and jailhouse disable and the system should not hangs

I have attached the jailhouse-hardware-check
hardware check details
and the corresponding file sysconfig.c vmx.c svm.c grub

Thank you
Ashokkumar

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


jailhouse
Description: Binary data
/*
 * Jailhouse, a Linux-based partitioning hypervisor
 *
 * Copyright (c) Siemens AG, 2014-2017
 *
 * This work is licensed under the terms of the GNU GPL, version 2.  See
 * the COPYING file in the top-level directory.
 *
 * Alternatively, you can use or redistribute this file under the following
 * BSD license:
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions
 * are met:
 *
 * 1. Redistributions of source code must retain the above copyright
 *notice, this list of conditions and the following disclaimer.
 *
 * 2. Redistributions in binary form must reproduce the above copyright
 *notice, this list of conditions and the following disclaimer in the
 *documentation and/or other materials provided with the distribution.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
 * THE POSSIBILITY OF SUCH DAMAGE.
 *
 * Configuration for System manufacturer System Product Name
 * created with 'tools/jailhouse config create sysconfig.c'
 *
 * NOTE: This config expects the following to be appended to your kernel cmdline
 *   "memmap=0x420$0x3a00"
 */

#include 
#include 

#define ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0]))

struct {
	struct jailhouse_system header;
	__u64 cpus[1];
	struct jailhouse_memory mem_regions[53];
	struct jailhouse_irqchip irqchips[1];
	__u8 pio_bitmap[0x2000];
	struct jailhouse_pci_device pci_devices[13];
	struct jailhouse_pci_capability pci_caps[34];
} __attribute__((packed)) config = {
	.header = {
		.signature = JAILHOUSE_SYSTEM_SIGNATURE,
		.revision = JAILHOUSE_CONFIG_REVISION,
		.flags = JAILHOUSE_SYS_VIRTUAL_DEBUG_CONSOLE,
		.hypervisor_memory = {
			.phys_start = 0x3a00,
			.size = 0x400,
		},
		.debug_console = {
			

Re: [PATCH] x86: Fix CONFIG_CRASH_CELL_ON_PANIC

2018-10-22 Thread Ashok kumar
Hi,

I have added
 void vcpu_park(void)
 {
 #ifdef CONFIG_CRASH_CELL_ON_PANIC
-   if (this_cpu_data()->failed) {
+   if (this_cpu_public()->failed) {
this_cpu_data()->vmcb.rip = 0;
return;
}

 void vcpu_park(void)
 {
 #ifdef CONFIG_CRASH_CELL_ON_PANIC
-   if (this_cpu_data()->failed) {
+   if (this_cpu_public()->failed) {
vmcs_write64(GUEST_RIP, 0);
return;
}


in the corresponding files arch/hypervisor/arch/x86/vmx.c
  arch/hypervisor/arch/x86/svm.c
and after executing  command

sudo tools/jailhouse enable configs/x86/sysconfig.cell

in syslog the following message is I get


texsonics kernel: [  174.219041]  The Jailhouse is opening.
Oct 22 18:01:01 texsonics kernel: [  244.918968] Broke affinity for irq 125
Oct 22 18:01:01 texsonics kernel: [  244.920002] smpboot: CPU 3 is now
offline

sudo tools/jailhouse cell create configs/x86/apic-demo.cell

smpboot: CPU 3 is now offline
Oct 22 18:01:01 texsonics kernel: [  244.947989] Created Jailhouse cell
"apic-demo"
Oct 22 18:01:03 texsonics /usr/sbin/irqbalance: WARNING, didn't collect
load info for all cpus, balancing is broken
Oct 22 18:02:43 texsonics /usr/sbin/irqbalance: message repeated 16 times:
[ WARNING, didn't collect load info for all cpus, balancing is broken]
Oct 22 18:02:53 texsonics /usr/sbin/irqbalance: WARNING, didn't collect
load info for all cpus, balancing is broken

sudo tools/jailhouse cell destroy apic-demo

smpboot: Booting Node 0 Processor 3 APIC 0x3
Oct 22 18:05:04 texsonics kernel: [  488.138877] Destroyed Jailhouse cell
"apic-demo"

and my system gets hangs and in my UART  I get

Stopped APIC demo
Closing cell "apic-demo"
Page pool usage after cell destruction mem 295/15823, remap 16394/131072
cpu 3 received SIPI,vector 97

kindly help me to solve this issue, so that I should able to destroy
jailhouse cell and jailhouse disable

Thank you
Ashokkumar


On Wed, Oct 17, 2018 at 6:37 PM Jan Kiszka  wrote:

> As it is not enabled by default, this became silently broken.
>
> Fixes: 13c472715e29 ("core: Move failed into public per-cpu section")
> Signed-off-by: Jan Kiszka 
> ---
>  hypervisor/arch/x86/svm.c | 2 +-
>  hypervisor/arch/x86/vmx.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/hypervisor/arch/x86/svm.c b/hypervisor/arch/x86/svm.c
> index 1808e74e..eb757a87 100644
> --- a/hypervisor/arch/x86/svm.c
> +++ b/hypervisor/arch/x86/svm.c
> @@ -980,7 +980,7 @@ vmentry:
>  void vcpu_park(void)
>  {
>  #ifdef CONFIG_CRASH_CELL_ON_PANIC
> -   if (this_cpu_data()->failed) {
> +   if (this_cpu_public()->failed) {
> this_cpu_data()->vmcb.rip = 0;
> return;
> }
> diff --git a/hypervisor/arch/x86/vmx.c b/hypervisor/arch/x86/vmx.c
> index 29967015..27e6e4e8 100644
> --- a/hypervisor/arch/x86/vmx.c
> +++ b/hypervisor/arch/x86/vmx.c
> @@ -910,7 +910,7 @@ void vcpu_nmi_handler(void)
>  void vcpu_park(void)
>  {
>  #ifdef CONFIG_CRASH_CELL_ON_PANIC
> -   if (this_cpu_data()->failed) {
> +   if (this_cpu_public()->failed) {
> vmcs_write64(GUEST_RIP, 0);
> return;
> }
> --
> 2.16.4
>
> --
> You received this message because you are subscribed to the Google Groups
> "Jailhouse" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to jailhouse-dev+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: how to shut down jailhouse and apic demo

2018-10-18 Thread Ashok kumar
Hi,

I did not get config.h file in folder  include/jailhouse/config.h

 /usr/src/jailhouse-master/include/jailhouse# ls
cell-config.hconsole.h  hypercall.h

but still I added #define CONFIG_CRASH_CELL_ON_PANIC 1 in
in cell-config.h I got this error on *make* command

/usr/src/jailhouse-master/hypervisor/arch/x86/svm.c: In function
‘vcpu_park’:
/usr/src/jailhouse-master/hypervisor/arch/x86/svm.c:983:21: error: ‘struct
per_cpu’ has no member named ‘failed’
  if (this_cpu_data()->failed) {
 ^
make[4]: *** [/usr/src/jailhouse-master/hypervisor/arch/x86/svm.o] Error 1
make[3]: *** [/usr/src/jailhouse-master/hypervisor/arch/x86] Error 2
make[2]: *** [/usr/src/jailhouse-master/hypervisor] Error 2
make[1]: *** [_module_/usr/src/jailhouse-master] Error 2
make: *** [modules] Error 2

kindly help me to get config.h file

Thank you
Ashok

On Mon, Oct 15, 2018 at 4:48 PM Jan Kiszka  wrote:

> On 13.10.18 09:38, Ashok kumar wrote:
> > Hi,
> >
> > Timer fired , jitter 1080 ns , min 420 ns max: 15003 ns
> >
> > using jailhouse cell destroy apic-demo
> >
> > sudo tools/jailhouse cell destroy apic-demo
> >
> > I received the below in the UART serial
> >
> > stopped apic demo
> >
> > Closing cell “apic-demo”
> >
> > page pool usage after cell destruction : mem 298/15823 , remap
> 16394/131072
> >
> > CPU 3 received SIPI, vector 97
> >
> > after opening another terminal
> >
> >  >> sudo tools/jailhouse disable
> >
> > shutting down hypervisor
> >
> > Releasing CPU 2
> >
> > Releasing CPU 3
> >
> > Releasing CPU 0
> >
> > Releasing CPU 1
> >
> >
> > after this I am not able to use other applications, my system becomes
> very slow
> > and hangs.
> >
> > so I have to shut-down my system, It is not shutting down, so I have to
> reset my
> > system completely.
> >
> >
> >
> > and I have attached screen shot of  error message after executing
> > sudo tools/jailhouse cell destroy apic-demo
> >
> > Fatal : Unhandled VM-Exit reason 26
>
> The root cell attempts to issue vmxoff for some reason. You could add
>
> #define CONFIG_CRASH_CELL_ON_PANIC 1
>
> to include/jailhouse/config.h (or create that file first) and see what
> backtrace
> in Linux this will trigger. Usually, that gives an idea what Linux tried
> to do
> when it caused the violation. Maybe it ran into a crash and called
> cpu_emergency_vmxoff().
>
> Jan
>
> > and my system hangs
> >
> > Kindly help me to use other applications in my system after executing
> >
> >  >> sudo tools/jailhouse cell destroy apic-demo
> >
> > and
> >
> >  >> sudo tools/jailhouse disable
> >
> >
> > Thank you
> >
> > R.Ashokkumar
> >
> >
> >
> >
> > On Thu, Oct 11, 2018 at 6:08 PM Ralf Ramsauer <
> ralf.ramsa...@oth-regensburg.de
> > <mailto:ralf.ramsa...@oth-regensburg.de>> wrote:
> >
> >
> > On 10/11/18 2:30 PM, Ashok kumar wrote:
> >  > Hi,
> >  >
> >  > insmod jailhouse.ko
> >  >
> >  > sudo tools/jailhouse enable configs/x86/sysconfig.cell
> >  >
> >  > sudo tools/jailhouse cell create configs/x86/apic-demo.cell
> >  >
> >  > sudo tools/jailhouse cell load apic-demo
> inmates/demos/x86/apic-demo.bin
> >  >
> >  > sudo tools/jailhouse cell start apic-demo
> >  >
> >  >  sudo tools/jailhouse cell list
> >  >
> >  > sudo tools/jailhouse cell stats apic-demo
> >  >
> >  > I am able to see root cell and apic-demo cell
> >  >
> >  > sudo tools/jailhouse cell shutdown apic-demo
> >
> > Try to destroy the cell first and see if the root cell survives.
> >
> >  >
> >  > sudo tools/jailhouse disable configs/x86/sysconfig.cell
> >
> > Just run 'jailhouse disable' without any further arguments -- no
> need to
> > provide the cell configuration.
> >
> >  >
> >  > after shutdown and disable using the above commands my system
> hangs
> >  >
> >  > and I am not able to use other application
> >
> > Again, please provide detailed information about your problem, such
> as
> > console output. I'm pretty we can find helpful output there.
> >
> >Ralf
> >
> >  >
> >  >
> >  > Kindly provide me the proper way to come out 

how to shut down jailhouse and apic demo

2018-10-11 Thread Ashok kumar
Hi,

insmod jailhouse.ko

sudo tools/jailhouse enable configs/x86/sysconfig.cell

sudo tools/jailhouse cell create configs/x86/apic-demo.cell

sudo tools/jailhouse cell load apic-demo inmates/demos/x86/apic-demo.bin

sudo tools/jailhouse cell start apic-demo

 sudo tools/jailhouse cell list

sudo tools/jailhouse cell stats apic-demo

I am able to see root cell and apic-demo cell

sudo tools/jailhouse cell shutdown apic-demo

sudo tools/jailhouse disable configs/x86/sysconfig.cell

after shutdown and disable using the above commands my system hangs

and I am not able to use other application


Kindly provide me the proper way to come out of jailhouse rootcell and
apic-demo cell, so that my system doesn’t hangs, and I can use my system
normally

as usual.


Thank you

R.Ashok kumar

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


apic-demo error

2018-10-11 Thread Ashok kumar
Hi,

I am using UART to debug the jailhouse and I have attached the image of
error details when I executed the commands below

insmod jailhouse.ko
sudo tools/jailhouse enable configs/x86/sysconfig.cell
sudo tools/jailhouse cell create configs/x86/apic-demo.cell
 sudo tools/jailhouse cell load apic-demo inmates/demos/x86/apic-demo.bin
-a 0xf
root@texsonics:/usr/src/jailhouse-master# sudo tools/jailhouse cell start
apic-demo
root@texsonics:/usr/src/jailhouse-master# sudo tools/jailhouse cell list
ID  NameState Assigned CPUs
Failed CPUs
0   RootCellrunning
0-2
1   apic-demo   failed3
3

my kernel configuration is as follows
/usr/src/jailhouse-master# cat /proc/cmdline
BOOT_IMAGE=/vmlinuz-4.9.90-xenomai-3.0.x
root=UUID=4d4bf369-b4ad-4a82-9d57-0baf52deefce ro quiet splash
intel_iommu=off intremap=on memmap=0x420$0x3a00 kvm-intel.nested=1
vt.handoff=7
root@texsonics:/usr/src/jailhouse-master#
**

[image: image.png]

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


How to run the script ./build-images.sh to get QEMU/KVM Intel-x86 virtual target

2018-10-10 Thread Ashok kumar
Hi,

How to run the script ./build-images.sh to get QEMU/KVM Intel-x86 virtual
target image , and to get all the images
I dont understand how to run docker args

-e --docker-argsAdditional arguments to pass to docker for running the
build.'
below is the method I have run the script

jailhouse-images-master# ./build-images.sh
Available images demo images:
 1: QEMU/KVM Intel-x86 virtual target
 2: QEMU ARM64 virtual target
 3: Orange Pi Zero (256 MB edition)
 4: Intel NUC (NUC6CAY, 8 GB RAM)
 5: Marvell ESPRESSObin (1 GB edition)
 6: LeMaker HiKey (2 GB edition)
 0: all (may take hours...)

Select images to build (space-separated index list): 1
1
docker: invalid reference format.
See 'docker run --help'.
root@texsonics:/home/texsonics/Desktop/Jailhouse
documentation/jailhouse-images-master# ./build-images.sh  QEMU/KVM
Intel-x86 virtual target
Usage: ./build-images.sh [OPTIONS]
-e
Options:
-e --latestBuild latest Jailhouse version from next branch.
-e --allBuild all available images (may take hours...).
-e --shellDrop into a shell to issue bitbake commands manually.
-e --docker-argsAdditional arguments to pass to docker for running the
build.

kindly help me to get all the images

Thank you
Ashok

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


how to run the script ./build-images.sh for 1: QEMU/KVM Intel-x86 virtual target

2018-10-08 Thread Ashok kumar
Hi,


I am using the below link to download the image

`https://github.com/siemens/jailhouse-images


and my docker --version
Docker version 17.09.0-ce, build afdb6d4

when l run the script

./build-images.sh
Available images demo images:
 1: QEMU/KVM Intel-x86 virtual target
 2: QEMU ARM64 virtual target
 3: Orange Pi Zero (256 MB edition)
 4: Intel NUC (NUC6CAY, 8 GB RAM)
 5: Marvell ESPRESSObin (1 GB edition)
 6: LeMaker HiKey (2 GB edition)
 0: all (may take hours...)

Select images to build (space-separated index list): 1
1
docker: invalid reference format.
See 'docker run --help'.

how the run the script ./build-images.sh with input parameters

to get the image   1: QEMU/KVM Intel-x86 virtual target

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


drm:gen8_irq_handler [i915]] *ERROR* Fault errors on pipe A 0x00000080

2018-10-08 Thread Ashok kumar
 Hi,

After enabling jailhouse I get the following message in syslog
sudo tools/jailhouse enable configs/x86/sysconfig.cell


*drm:gen8_irq_handler [i915]] *ERROR* Fault errors on pipe A0x0080*

I am using the mother board details

sudo dmidecode --string baseboard-product-name

# SMBIOS implementations newer than version 2.8 are not

# fully supported by this version of dmidecode.

*H110M-D *

and I have enabled Vtx -Vt-d

in boot parameters are as follows
cat /proc/cmdline

*BOOT_IMAGE=/vmlinuz-4.9.90-xenomai-3.0.x
root=UUID=4d4bf369-b4ad-4a82-9d57-0baf52deefce ro quiet splash
intel_iommu=off intremap=on memmap=69M$0x3a00 kvm-intel.nested=1
vt.handoff=7*


kindly help me to solve this problem

Thank you

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


drm:gen8_irq_handler [i915]] *ERROR* Fault errors on pipe A

2018-10-08 Thread Ashok kumar
Hi,

After enabling jailhouse I get the following message in syslog

sudo tools/jailhouse enable configs/x86/sysconfig.cell

drm:gen8_irq_handler [i915]] *ERROR* Fault errors on pipe A
0x0080

kindly help me to solve this problem

Thank you

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


irq_handler [i915]] *ERROR* Fault errors on pipe A Oct 4 16:34:20 texsonics kernel: [ 619.693975] : 0x00000080

2018-10-04 Thread Ashok kumar
Hi,
after doing the following commands

insmod jailhouse.ko

sudo tools/jailhouse enable configs/x86/sysconfig.cell

sudo tools/jailhouse cell create configs/x86/apic-demo.cell

sudo tools/jailhouse cell load apic-demo inmates/demos/x86/apic-demo.bin

sudo tools/jailhouse cell start apic-demo

I get  the following errors in dmesg

[drm:gen8_irq_handler [i915]] *ERROR* Fault errors on pipe A
Oct  4 16:34:20 texsonics kernel: [  619.693921] : 0x0080


I am not able to destroy or shut down apic-demo,

If I destroy or shut-down the apic-demo my  system hangs.


kindly help me in this issue

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: jailhouse: loading out-of-tree module taints kernel.

2018-10-02 Thread Ashok kumar
Hi,
I have compiled and trying to enable the jailhouse I get Device or resource
busy
as mentioned below.
JAILHOUSE_ENABLE: Device or resource busy

root@tex:/usr/src/jailhouse-master# sudo tools/jailhouse enable
configs/x86/sysconfig.cell
JAILHOUSE_ENABLE: Device or resource busy
root@tex:/usr/src/jailhouse-master# sudo tools/jailhouse cell create
configs/x86/tiny-demo.cell
JAILHOUSE_CELL_CREATE: Invalid argument

kindly support me.

Thank
Ashok






On Mon, Oct 1, 2018 at 6:36 PM Jan Kiszka  wrote:

> On 01.10.18 13:42, Ashok kumar wrote:
> > Hi I am using xenomai -3.0.x patched with linux kernel 4.9.90-
> >
> > After signing the modules with the absolute path
> >
> > /sign-file sha512 /usr/src/linux-4.9.90/certs/signing_key.pem
> > /usr/src/linux-4.9.90/certs/signing_key.x509
> > /usr/src/jailhouse-master/driver/jailhouse.ko
> >
> >   I solved the error  which has occurred before as mentioned below.
> >
> > SSL error:02001002:system library:fopen:No such file or directory:
> bss_file.c:169
> >> - SSL error:2006D080:BIO routines:BIO_new_file:no such file:
> bss_file.c:172
> >> sign-file: certs/signing_key.pem: No such file or directory
> >
> > But still when using insmod jailhouse.ko.
> >
> >
> > to load the module  jailhouse.ko. in dmesg I am getting
> >
> > jailhouse: loading out-of-tree module taints kernel.
> >
> > How to get dmesg | tail message log
> >
> > The Jailhouse is opening
> >
>
> That is printed once you do "jailhouse enable ..." successfully.
>
> Jan
>
> --
> Siemens AG, Corporate Technology, CT RDA IOT SES-DE
> Corporate Competence Center Embedded Linux
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


jailhouse: loading out-of-tree module taints kernel.

2018-10-01 Thread Ashok kumar
Hi I am using xenomai -3.0.x patched with linux kernel 4.9.90-

After signing the modules with the absolute path

/sign-file sha512 /usr/src/linux-4.9.90/certs/signing_key.pem
/usr/src/linux-4.9.90/certs/signing_key.x509
/usr/src/jailhouse-master/driver/jailhouse.ko

 I solved the error  which has occurred before as mentioned below.

SSL error:02001002:system library:fopen:No such file or directory:
bss_file.c:169
> - SSL error:2006D080:BIO routines:BIO_new_file:no such file:
bss_file.c:172
> sign-file: certs/signing_key.pem: No such file or directory

But still when using insmod jailhouse.ko.


to load the module  jailhouse.ko. in dmesg I am getting

jailhouse: loading out-of-tree module taints kernel.

How to get dmesg | tail message log

The Jailhouse is opening


Kindly help me to solve this issue


Thank you

Ashok

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


jailhouse: loading out-of-tree module taints kernel. [14852.317443] jailhouse: module verification f

2018-09-25 Thread Ashok kumar
Hi,

Iam using  4.4.0-135-generic

and  I am trying to install jailhouse-0.9 while installing make install I get 
the following message

At main.c:222:
- SSL error:02001002:system library:fopen:No such file or directory: 
bss_file.c:169
- SSL error:2006D080:BIO routines:BIO_new_file:no such file: bss_file.c:172
sign-file: certs/signing_key.pem: No such file or directory

and after loading insmod jailhouse.ko

I get the following message in dmesg

 jailhouse: loading out-of-tree module taints kernel.
[14852.317443] jailhouse: module verification failed: signature and/or required 
key missing - tainting kernel

kindly help me to solve this issue.

Thank you
Ashokkumar

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jailhouse-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: Loading kernel on Non-root cell in jetson-TX2.

2018-01-15 Thread Ashok Kumar
Hi,

Thank you all, earlier i was facing issue with unpacking initramfs, As Jan
suggested to tweak with memory layout i have resolved that issue
unfortunately stuck with another one.

 As i am trying to boot 4.14 upstream kernel(maintained by Jan) into
non-root cell on TX2, i am facing issues related to loading of images and
rootfs.

I have referred non-root cell configs of other platform and created one for
TX2, i want  to understand the role of virt_start and how to calculate
these addresses?

I have attached Tx2 non-root cell config file and dtb file, with this
configuration i am getting following logs.


Started cell "jetson-tx2-linux-demo"
[0.00] Booting Linux on physical CPU 0x102
[0.00] Linux version 4.14.0-rc4 (root@tegra-ubuntu) (gcc version
5.3.1 20160413 (Ubuntu/Linaro 5.3.1-14ubuntu2.1)) #2 SMP PREEMPT Wed 8
[0.00] Boot CPU: AArch64 Processor [411fd073]
[0.00] Machine model: Jailhouse cell on NVIDIA Jetson TX2
[0.00] efi: Getting EFI parameters from FDT:
[0.00] efi: UEFI not found.
[0.00] cma: Reserved 16 MiB at 0xff00
[0.00] psci: probing for conduit method from DT.
[0.00] psci: PSCIv0.2 detected in firmware.
[0.00] psci: Using standard PSCI v0.2 function IDs
[0.00] psci: MIGRATE_INFO_TYPE not supported.
[0.00] percpu: Embedded 21 pages/cpu @800042cb5000 s47128 r8192
d30696 u86016
[0.00] Detected PIPT I-cache on CPU0
[0.00] Built 1 zonelists, mobility grouping on.  Total pages: 108092
[0.00] Kernel command line: console=ttyS0,115200
[0.00] PID hash table entries: 2048 (order: 2, 16384 bytes)
[0.00] Dentry cache hash table entries: 65536 (order: 7, 524288
bytes)
[0.00] Inode-cache hash table entries: 32768 (order: 6, 262144
bytes)
[0.00] software IO TLB [mem 0xfafff000-0xfefff000] (64MB) mapped at
[80003afff000-80003effefff]
[0.00] Memory: 295476K/439232K available (8956K kernel code, 1084K
rwdata, 4052K rodata, 1088K init, 282K bss, 127372K reserved, 16384)
[0.00] Virtual kernel memory layout:
[0.00] modules : 0x - 0x0800   (
 128 MB)
[0.00] vmalloc : 0x0800 - 0x7dffbfff
 (129022 GB)
[0.00]   .text : 0x0808 - 0x0894   (
8960 KB)
[0.00] .rodata : 0x0894 - 0x08d4   (
4096 KB)
[0.00]   .init : 0x08d4 - 0x08e5   (
1088 KB)
[0.00]   .data : 0x08e5 - 0x08f5f200   (
1085 KB)
[0.00].bss : 0x08f5f200 - 0x08fa5be0   (
 283 KB)
[0.00] fixed   : 0x7dfffe7fd000 - 0x7dfffec0   (
4108 KB)
[0.00] PCI I/O : 0x7dfffee0 - 0x7de0   (
16 MB)
[0.00] vmemmap : 0x7e00 - 0x8000   (
2048 GB maximum)
[0.00]   0x7ea0 - 0x7e00010b3c00   (
 6 MB actual)
[0.00] memory  : 0x80002800 - 0x800042cf   (
 428 MB)
[0.00] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[0.00] Preemptible hierarchical RCU implementation.
[0.00]  RCU restricting CPUs from NR_CPUS=64 to nr_cpu_ids=2.
[0.00]  Tasks RCU enabled.
[0.00] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2
[0.00] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[0.00] arch_timer: cp15 timer(s) running at 31.25MHz (virt).
[0.00] clocksource: arch_sys_counter: mask: 0xff
max_cycles: 0xe6a171046, max_idle_ns: 881590405314 ns
[0.02] sched_clock: 56 bits at 31MHz, resolution 32ns, wraps every
4398046511088ns
[0.53] Console: colour dummy device 80x25
[0.68] Calibrating delay loop (skipped), value calculated using
timer frequency.. 62.50 BogoMIPS (lpj=125000)
[0.76] pid_max: default: 32768 minimum: 301
[0.000118] Security Framework initialized
[0.000139] Mount-cache hash table entries: 1024 (order: 1, 8192 bytes)
[0.000145] Mountpoint-cache hash table entries: 1024 (order: 1, 8192
bytes)
[0.016037] ASID allocator initialised with 65536 entries
[0.024034] Hierarchical SRCU implementation.
[0.032146] EFI services will not be available.
[0.040058] smp: Bringing up secondary CPUs ...
[0.068122] Detected PIPT I-cache on CPU1
[0.068158] CPU1: Booted secondary processor [411fd073]
[0.068206] smp: Brought up 1 node, 2 CPUs
[0.068214] SMP: Total of 2 processors activated.
[0.068220] CPU features: detected feature: 32-bit EL0 Support
[0.068351] CPU: All CPU(s) started at EL1
[0.068696] devtmpfs: initialized
[0.068965] random: get_random_u32 called from
bucket_table_alloc+0x108/0x288 with crng_init=0
[0.069155] clocksource: jiffies: mask: 0x max_cycles:
0x, max_idle_ns: 764504178510 ns
[0.069164] 

Re: Loading kernel on Non-root cell in jetson-TX2.

2018-01-15 Thread Ashok Kumar
Hi,

Thank you all, earlier i was facing issue with unpacking initramfs, As Jan
suggested to tweak with memory layout i have resolved that issue
unfortunately stuck with another one.

 As i am trying to boot 4.14 upstream kernel(maintained by Jan) into
non-root cell on TX2, i am facing issues related to loading of images and
rootfs.

I have referred non-root cell configs of other platform and created one for
TX2, i want  to understand the role of virt_start and how to calculate
these addresses?

I have attached Tx2 non-root cell config file and dtb file, with this
configuration i am getting following logs.



Cell "jetson-tx2-linux-demo" can be loaded
Started cell "jetson-tx2-linux-demo"
[0.00] Booting Linux on physical CPU 0x102
[0.00] Linux version 4.14.0-rc4 (root@tegra-ubuntu) (gcc version
5.3.1 20160413 (Ubuntu/Linaro 5.3.1-14ubuntu2.1)) #2 SMP PREEMPT Wed 8
[0.00] Boot CPU: AArch64 Processor [411fd073]
[0.00] Machine model: Jailhouse cell on NVIDIA Jetson TX2
[0.00] efi: Getting EFI parameters from FDT:
[0.00] efi: UEFI not found.
[0.00] cma: Reserved 16 MiB at 0xff00
[0.00] psci: probing for conduit method from DT.
[0.00] psci: PSCIv0.2 detected in firmware.
[0.00] psci: Using standard PSCI v0.2 function IDs
[0.00] psci: MIGRATE_INFO_TYPE not supported.
[0.00] missing boot CPU MPIDR, not enabling secondaries
[0.00] percpu: Embedded 21 pages/cpu @80005bcca000 s47128 r8192
d30696 u86016
[0.00] Detected PIPT I-cache on CPU0
[0.00] Built 1 zonelists, mobility grouping on.  Total pages: 208892
[0.00] Kernel command line: console=ttyS0,115200
[0.00] PID hash table entries: 4096 (order: 3, 32768 bytes)
[0.00] Dentry cache hash table entries: 131072 (order: 8, 1048576
bytes)
[0.00] Inode-cache hash table entries: 65536 (order: 7, 524288
bytes)
[0.00] software IO TLB [mem 0xfafff000-0xfefff000] (64MB) mapped at
[80003afff000-80003effefff]
[0.00] Memory: 711292K/848832K available (8956K kernel code, 1084K
rwdata, 4052K rodata, 1088K init, 282K bss, 121156K reserved, 16384)
[0.00] Virtual kernel memory layout:
[0.00] modules : 0x - 0x0800   (
 128 MB)
[0.00] vmalloc : 0x0800 - 0x7dffbfff
 (129022 GB)
[0.00]   .text : 0x0808 - 0x0894   (
8960 KB)
[0.00] .rodata : 0x0894 - 0x08d4   (
4096 KB)
[0.00]   .init : 0x08d4 - 0x08e5   (
1088 KB)
[0.00]   .data : 0x08e5 - 0x08f5f200   (
1085 KB)
[0.00].bss : 0x08f5f200 - 0x08fa5be0   (
 283 KB)
[0.00] fixed   : 0x7dfffe7fd000 - 0x7dfffec0   (
4108 KB)
[0.00] PCI I/O : 0x7dfffee0 - 0x7de0   (
16 MB)
[0.00] vmemmap : 0x7e00 - 0x8000   (
2048 GB maximum)
[0.00]   0x7ea0 - 0x7e00016f3c00   (
12 MB actual)
[0.00] memory  : 0x80002800 - 0x80005bcf   (
 828 MB)
[0.00] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[0.00] Preemptible hierarchical RCU implementation.
[0.00]  RCU restricting CPUs from NR_CPUS=64 to nr_cpu_ids=1.
[0.00]  Tasks RCU enabled.
[0.00] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[0.00] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[0.00] arch_timer: cp15 timer(s) running at 31.25MHz (virt).
[0.00] clocksource: arch_sys_counter: mask: 0xff
max_cycles: 0xe6a171046, max_idle_ns: 881590405314 ns
[0.02] sched_clock: 56 bits at 31MHz, resolution 32ns, wraps every
4398046511088ns
[0.52] Console: colour dummy device 80x25
[0.67] Calibrating delay loop (skipped), value calculated using
timer frequency.. 62.50 BogoMIPS (lpj=125000)
[0.75] pid_max: default: 32768 minimum: 301
[0.000119] Security Framework initialized
[0.000140] Mount-cache hash table entries: 2048 (order: 2, 16384 bytes)
[0.000148] Mountpoint-cache hash table entries: 2048 (order: 2, 16384
bytes)
[0.016032] ASID allocator initialised with 65536 entries
[0.024031] Hierarchical SRCU implementation.
[0.032139] EFI services will not be available.
[0.040053] smp: Bringing up secondary CPUs ...
[0.040059] smp: Brought up 1 node, 1 CPU
[0.040063] SMP: Total of 1 processors activated.
[0.040069] CPU features: detected feature: 32-bit EL0 Support
[0.040128] CPU: All CPU(s) started at EL1
[0.040472] devtmpfs: initialized
[0.040743] random: get_random_u32 called from
bucket_table_alloc+0x108/0x288 with crng_init=0
[0.044148] clocksource: jiffies: mask: 0x max_cycles:
0x, max_idle_ns: 764504178510 ns
[