Bug 1283892

Summary: dracut doesn't see CONFIG_MICROCODE_[AMD|INTEL]_EARLY after kernel changes
Product: [Fedora] Fedora Reporter: Harald Hoyer <harald>
Component: dracutAssignee: dracut-maint-list
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 23CC: dracut-maint-list, extras-qa, fedora, harald, jonathan, jwboyer, kay, kevin, pbrobinson, zbyszek
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: dracut-043-61.git20151120.fc23 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1278938 Environment:
Last Closed: 2015-11-23 20:53:47 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1278938    
Bug Blocks:    

Description Harald Hoyer 2015-11-20 08:04:02 UTC
+++ This bug was initially created as a clone of Bug #1278938 +++

On installing rawhide kernels I see: 

Disabling early microcode, because kernel does not support it. CONFIG_MICROCODE_[AMD|INTEL]_EARLY!=y

The kernel options may have changed here so dracut needs to adjust to whatever it is now. 

% sudo dnf install kernel*
Last metadata expiration check performed 0:13:16 ago on Fri Nov  6 11:38:40 2015.
Dependencies resolved.
====================================================================================================
 Package                     Arch          Version                        Repository           Size
====================================================================================================
Installing:
 kernel                      x86_64        4.4.0-0.rc0.git4.1.fc24        @commandline         50 k
 kernel-core                 x86_64        4.4.0-0.rc0.git4.1.fc24        @commandline         21 M
 kernel-devel                x86_64        4.4.0-0.rc0.git4.1.fc24        @commandline         10 M
 kernel-modules              x86_64        4.4.0-0.rc0.git4.1.fc24        @commandline         18 M
 kernel-modules-extra        x86_64        4.4.0-0.rc0.git4.1.fc24        @commandline        2.3 M
Removing:
 kernel                      x86_64        4.3.0-1.fc24                   @rawhide              0  
 kernel-core                 x86_64        4.3.0-1.fc24                   @rawhide             51 M
 kernel-devel                x86_64        4.3.0-1.fc24                   @koji                37 M
 kernel-modules              x86_64        4.3.0-1.fc24                   @rawhide             17 M
 kernel-modules-extra        x86_64        4.3.0-1.fc24                   @rawhide            2.1 M

Transaction Summary
====================================================================================================
Install  5 Packages
Remove   5 Packages

Total size: 52 M
Is this ok [y/N]: y
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Installing  : kernel-core-4.4.0-0.rc0.git4.1.fc24.x86_64                                     1/10 
  Installing  : kernel-modules-4.4.0-0.rc0.git4.1.fc24.x86_64                                  2/10 
  Installing  : kernel-modules-extra-4.4.0-0.rc0.git4.1.fc24.x86_64                            3/10 
  Installing  : kernel-4.4.0-0.rc0.git4.1.fc24.x86_64                                          4/10 
  Installing  : kernel-devel-4.4.0-0.rc0.git4.1.fc24. [===========                          ]  5/10Terminated.
  Installing  : kernel-devel-4.4.0-0.rc0.git4.1.fc24.x86_64                                    5/10 
  Erasing     : kernel-4.3.0-1.fc24.x86_64                                                     6/10 
  Erasing     : kernel-devel-4.3.0-1.fc24.x86_64                                               7/10 
  Erasing     : kernel-modules-extra-4.3.0-1.fc24.x86_64                                       8/10 
  Erasing     : kernel-modules-4.3.0-1.fc24.x86_64                                             9/10 
warning: file /lib/modules/4.3.0-1.fc24.x86_64/kernel/drivers/platform/x86/ideapad-laptop.ko.xz: remove failed: No such file or directory
  Erasing     : kernel-core-4.3.0-1.fc24.x86_64                                               10/10 
warning: file /lib/modules/4.3.0-1.fc24.x86_64/kernel/drivers/i2c/busses/i2c-designware-platform.ko.xz: remove failed: No such file or directory
Disabling early microcode, because kernel does not support it. CONFIG_MICROCODE_[AMD|INTEL]_EARLY!=y
  Verifying   : kernel-modules-extra-4.4.0-0.rc0.git4.1.fc24.x86_64                            1/10 
  Verifying   : kernel-modules-4.4.0-0.rc0.git4.1.fc24.x86_64                                  2/10 
  Verifying   : kernel-devel-4.4.0-0.rc0.git4.1.fc24.x86_64                                    3/10 
  Verifying   : kernel-core-4.4.0-0.rc0.git4.1.fc24.x86_64                                     4/10 
  Verifying   : kernel-4.4.0-0.rc0.git4.1.fc24.x86_64                                          5/10 
  Verifying   : kernel-devel-4.3.0-1.fc24.x86_64                                               6/10 
  Verifying   : kernel-4.3.0-1.fc24.x86_64                                                     7/10 
  Verifying   : kernel-modules-4.3.0-1.fc24.x86_64                                             8/10 
  Verifying   : kernel-core-4.3.0-1.fc24.x86_64                                                9/10 
  Verifying   : kernel-modules-extra-4.3.0-1.fc24.x86_64                                      10/10 

Removed:
  kernel.x86_64 4.3.0-1.fc24                          kernel-core.x86_64 4.3.0-1.fc24              
  kernel-devel.x86_64 4.3.0-1.fc24                    kernel-modules.x86_64 4.3.0-1.fc24           
  kernel-modules-extra.x86_64 4.3.0-1.fc24           

Installed:
  kernel.x86_64 4.4.0-0.rc0.git4.1.fc24               kernel-core.x86_64 4.4.0-0.rc0.git4.1.fc24   
  kernel-devel.x86_64 4.4.0-0.rc0.git4.1.fc24         kernel-modules.x86_64 4.4.0-0.rc0.git4.1.fc24
  kernel-modules-extra.x86_64 4.4.0-0.rc0.git4.1.fc24

Complete!
sudo dnf install kernel*  59.96s user 112.06s system 112% cpu 2:33.30 total

--- Additional comment from Josh Boyer on 2015-11-06 14:30:44 EST ---

This is because of upstream kernel commit fe055896c040df571e4ff56fb196d6845130057b and this hunk of code in dracut:

if [[ $early_microcode = yes ]]; then
    if [[ $hostonly ]]; then
        [[ $(get_cpu_vendor) == "AMD" ]] \
            && ! check_kernel_config CONFIG_MICROCODE_AMD_EARLY \
            && unset early_microcode
        [[ $(get_cpu_vendor) == "Intel" ]] \
            && ! check_kernel_config CONFIG_MICROCODE_INTEL_EARLY \
            && unset early_microcode
    else
        ! check_kernel_config CONFIG_MICROCODE_AMD_EARLY \
            && ! check_kernel_config CONFIG_MICROCODE_INTEL_EARLY \
            && unset early_microcode
    fi
    [[ $early_microcode != yes ]] \
        && dwarn "Disabling early microcode, because kernel does not support it. CONFIG_MICROCODE_[AMD|INTEL]_EARLY!=y"
fi


Since the options no longer even exist in the kernel, they won't show up in the resulting config-<kernel version> installed file even though the functionality is still actually in the kernel.  I've emailed Harald and the upstream author of the kernel patch.

--- Additional comment from Thorsten Leemhuis on 2015-11-19 13:57:52 EST ---

@harald: What's the plan forward here? You afaics fixed it upstream by
http://git.kernel.org/cgit/boot/dracut/dracut.git/commit/?id=875426f2fc1360401ddb5f97c67df031e54958d5 which afaics made it to rawhide already. But everybody that installs a 4.4 kernel in f23 or earlier will get a initramfs without microcode update, which is not a good idea :-/

Comment 1 Fedora Update System 2015-11-20 08:17:33 UTC
dracut-043-61.git20151120.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-fb301ec952

Comment 2 Fedora Update System 2015-11-22 14:26:38 UTC
dracut-043-61.git20151120.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
If you want to test the update, you can install it with
$ su -c 'dnf --enablerepo=updates-testing update dracut'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-fb301ec952

Comment 3 Fedora Update System 2015-11-23 20:53:42 UTC
dracut-043-61.git20151120.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.