# Insert device GIGE into device with _ADR 0x001C0004
# (for Gigabyte motherboards)
#
into device label GIGE parent_adr 0x001C0004 remove_entry;
into device name_adr 0x001C0004 insert
begin
Device (GIGE)\n
{\n
    Name (_ADR, Zero)\n
    Name (_PRW, Package (0x02)\n
    {\n
        0x09,\n
        0x03\n
    })\n
    Method (EWOL, 1, NotSerialized)\n
    {\n
        If (LEqual (Arg0, One))\n
        {\n
            Or (GP9, One, GP9)\n
        }\n
        Else\n
        {\n
            And (GP9, Zero, GP9)\n
        }\n
        If (LEqual (Arg0, GP9))\n
        {\n
            Return (Zero)\n
        }\n
        Else\n
        {\n
            Return (One)\n
        }\n
    }\n
}
end;
into all code_regex
(OperationRegion\s\(GPIO,\sSystemIO,\s0x\d+,\s)0x05(\)\s*\n[^\n]+\n\s*\{\s*\n)((?:[^\n]+\n){5}\s*\})
replace_matched
begin
%10x06%2
                       GP9,    1,\n%3
end
