Live – AMD microcode update – how ?

Forum Forums New users New Users and General Questions Live – AMD microcode update – how ?

This topic contains 8 replies, has 4 voices, and was last updated by BitJam Jan 15-8:36 pm.

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #12696
    Member
    Avatar
    Ninho

    Hi ! I downloaded AntiX 17.2 (core) and carved to a CD-R. I expect it’s possible to update the AMD-microcode
    while running AntiX live from the CD, from the command line. If so, I’d like concise instructions for :
    – downloading & installing the appropriate packet(s) with newest AMD-64 mucode for my CPU.
    – applying the actual microcode patch to the CPU, without reboot (since this is not persistent).

    I have AMD A10 (‘Kaveri’ CPUID 00630F01). The Motherboard and BIOS manufacturers are NOT providinng upgrades, so I want
    to check applicability of AMD’s Spectre v2 mitigation and possible problems before I decide “modding” the BIOS by myself…
    or not ;=)

    CPUID : 630F01
    For reference, current microcode patch level (in BIOS) : 06003106
    Latest known to me microcode, including Spectre v2 mitigation : 06003109

    Thanks in advance…

    #15030
    Member
    Avatar
    Ninho

    Happy new year, All !

    Sorry to be following-up to my own post, but I’ve silently been waiting, hoping to get some answer for > 2 months!

    The question is to be able to install the microcode update package (amd64-microcode, from Debian, IIRC )
    onto a “frugal” installation of Antix Core, ultimate goal being to test microcode updating in Linux
    and benchmark my CPU (specs in the first post) with the newer microcodes.

    Whenever I try a : “sudo apt-get ” of said packet, it ends by saying it cannot find the base directory,
    I guess this is because of the way “frugal” and “persistence” are done. I could take detailed instructions
    for installing the microcode updates (and, I guess, an extra “initrd” to be passed by Grub to the kernel) so its is applied at system boot time – without doing an install-to-disk of AntiX.

    Thanks in advance to the Gurus !

    #15038
    Member
    Avatar
    skidoo

    Whenever I try a : “sudo apt-get ” of said packet, it ends by saying it cannot find the base directory,

    To ruleout the possibility that error message indicates a problem with the apt mechanism, I would manually download a copy of the .deb

    I’ve never tinkered with AMD microcode, so am guessing you’re looking for:
    https://debian.pkgs.org/9/debian-nonfree-amd64/amd64-microcode_3.20160316.3_amd64.deb.html
    or
    https://debian.pkgs.org/9/debian-nonfree-i386/amd64-microcode_3.20160316.3_i386.deb.html

    If the microcode .deb microcode installation is successful, does it generate a new, patched, kernel file?
    If it does, the antiX “live-kernel-updater” utility will then enable you to choose that new kernel and will (re)pack it into the initramfs.

    #16126
    Member
    linuxdaddy
    linuxdaddy

    Hello ninho,

    You’d have to make a new cd with each microde update but live-usb might be
    a more viable option.

    If you do a live-usb and install the microcode with it and do a remaster,
    it will have it burned in it and apply everytime you boot with the usb on a cpu.
    And when an updated microcode comes out all you have to do is update on
    the live stick and do a new remaster doesn’t have to be persistant.
    I don’t know about core but base should be able to.

    Linux = Many kinds, shapes, and sizes of computers to come
    together to create the ultimate cure for curiosity, boredom,
    creativity, and asylum. 🙂
    Whether new, used, young, or ancient.

    #16132
    Forum Admin
    BitJam
    BitJam

    I’m not sure how to download the latest microcode. I believe MX-18 has it. You can find out what package it is in from them. The microcode instructions are here: The Linux Microcode Loader.

    The punchline is this command that you need to run (as root):echo 1 > /sys/devices/system/cpu/microcode/reload

    For now, I suggest you install the microcode in the main file system and then run the above command in /etc/rc.local. If you want to avoid remastering you could add the microcode under the /antiX/xtra/lib/firmware directory. This will get copied into the main file system when it is being prepared by the live initrd.

    For antiX-19 and going forward we are planning to add the microcode to the live initrd and run the above command when the live initrd starts.

    If you would prefer to do it that way, it should be fairly easy with the /live/bin/unpack-initrd command. As root, run /live/bin/unpack-initrd
    This will create a initrd/ directory with the unpacked initrd below. Copy the microcode to the lib/firmware directory under initrd/ as per the instructions above. Then edit the initrd/init file and add the live above near the top of the main_wrapper() routine. Then when you are done repack the initrd with the command /live/bin/unpack-initrd -r Adding -r reverses what it does and repacks the initrd.gz from the initrd/ directory.

    Recent microcode is available from the MX-18 is file. It is in a cpio archive at /boot/initrd.img-4.19.0-1-amd64. That is an uncompressed cpio archive of size 44M.

    Context is worth 80 IQ points -- Alan Kay

    #16134
    Member
    linuxdaddy
    linuxdaddy

    I was talking about the micro-code package in the repos that way could update with
    each boot, but there is ” https://www.amd.com/en/corporate/security-updates
    and at the bottom is links to the manufacturers of the bios … hp dell acer etc.
    or specific os under the customer resources. I haven’t tried that
    ” /antiX/xtra/lib/firmware directory ” . or read only cd-r either.
    And you wrote: For antiX-19 and going forward I think you meant 18 not 19 🙂

    Linux = Many kinds, shapes, and sizes of computers to come
    together to create the ultimate cure for curiosity, boredom,
    creativity, and asylum. 🙂
    Whether new, used, young, or ancient.

    #16158
    Forum Admin
    BitJam
    BitJam

    I took last year off and anticapitalista decided not to release an antiX-18, only antiX-17 point releases. The next release of antiX will be antiX-19.

    Also, we aren’t going to add the mcirocode to our live initrd since the mirocode takes up about 44M. Instead it will be installed under /lib/firmare on the main file system and we will run the reload command from within the live initrd.

    I’m sorry if I misunderstood you linuxdaddy. Perhaps you and I are talking about different things. We are planning to have microcode loaded on the live system according to the kernel documentation I linked to above. If that’s not the same thing you were talking about, I apologize.

    Context is worth 80 IQ points -- Alan Kay

    #16235
    Member
    linuxdaddy
    linuxdaddy

    No need apoligize BitJam,

    I wasn’t talking about the install release..btw.thx for clarifying the 17 – 18 – 19 thing.
    I was talking about if someone makes a live it has to be a usb not a cd-r to save the new
    microcode to.

    Linux = Many kinds, shapes, and sizes of computers to come
    together to create the ultimate cure for curiosity, boredom,
    creativity, and asylum. 🙂
    Whether new, used, young, or ancient.

    #16242
    Forum Admin
    BitJam
    BitJam

    I was talking about if someone makes a live it has to be a usb not a cd-r to save the new microcode to.

    Gotcha! Thanks.

    Context is worth 80 IQ points -- Alan Kay

Viewing 9 posts - 1 through 9 (of 9 total)

You must be logged in to reply to this topic.