# RAM upgrade and Kernel panic on boot

## trumee

Hello,

I added a 4GB stick to my system upgrading it to 8GB RAM. The system now does a kernel panic boot (screenshot). The kernel is 64bit and i am able to boot OpenSuse fine. I ran memtest86 overnight and it passed too. Any body knows what kernel option is triggering this?

The kernel config is here

ThanksLast edited by trumee on Fri Jun 03, 2016 3:28 pm; edited 2 times in total

----------

## PeGa!

Aside from an esoteric kernel configuration, I don't see how a kernel config could trigger this behavior.

Some ideas:

- You've got in the gentoo kernel some kind of debug/security check intended for developers set on.

- You've got a ramdisk that went rogue.

- If opensuse is i386, that would explain why gentoo isn't able to boot (opensuse not being able to reach whole memory area will not complain about new corrupt memory, hence gentoo kernel crashing)

Did you try with genkernel?

----------

## pilla

trumee, your link for the kernel config is broken, pointing to the kernel oops.

Have you tried to switch the memory sticks?

----------

## trumee

 *pilla wrote:*   

> trumee, your link for the kernel config is broken, pointing to the kernel oops.
> 
> Have you tried to switch the memory sticks?

 

Sorry, updated the link. 

Changing the ram slots doesnt help. I tried a fresh config and the system booted fine. However, my system specific config is better, but i am not sure what is triiggering the kernel panic.

----------

## pilla

So I did some research on it. Looks like you got a call from swiotlb_full() (1), which means: 

```

/*

711          * Ran out of IOMMU space for this operation. This is very bad.

712          * Unfortunately the drivers cannot handle this operation properly.

713          * unless they check for dma_mapping_error (most don't)

714          * When the mapping is small enough return a static buffer to limit

715          * the damage, or panic when the transfer is too big.

716          */

```

So it looks like some driver for a device that uses DMA is giving IOMMU headaches. IOMMU is used for virtualization, are you running virtual machines (or inside one)? 

I would check off all IOMMU-related things in the kernel if they are not required for now and then test a new kernel.

----------

## trumee

 *pilla wrote:*   

> So I did some research on it. Looks like you got a call from swiotlb_full() (1), which means: 
> 
> ```
> 
> /*
> ...

 

I am not using virtualization. I disabled all IOMMU related options but still getting kernel panic.

```

$grep IOMMU .config

# CONFIG_GART_IOMMU is not set

# CONFIG_CALGARY_IOMMU is not set

CONFIG_IOMMU_HELPER=y

# CONFIG_IOMMU_SUPPORT is not set

# CONFIG_IOMMU_STRESS is not set

```

----------

## acidrums4

Hello there,

Did you manage to solve this? I'm facing this very issue. With a 2GB + 1GB RAM cards my laptop boots successfully, but with two 2GB cards it goes into a kernel panic when launching X (or even disabling X, a few seconds after giving a shell prompt it goes into kernel panic too).

----------

## Roman_Gruber

Download memtest and run it for each memory stick. just plug in one 2gb and test it

are those specs the same for the RAM modules?

lets assume your gentoo and your opensuse are both 64bit, than you could reuse suses kernel config. just check before as mentioned with e.g. top if the hole RAM is adressed in opensuse.

Bios update already checked? done?

I assume you are arleady using the latest kernel.org stable release? Any kernel bug is invalid anyway with dated kernels !

--

when you provide

laptop model, exact numbers

cpu / chipset 

manufacturer name for both ram modules.

--

a hardware defect can also not be ruled out. some guys can damage anything by just plug in something. those connectors are fragile. than ESD, scratch of the mainboard while opening the case and such ...

----------

