Function( Function { head: Destructured( FunctionHeadDestructured { ellipsis: true, identifier: None, arguments: [ FunctionHeadDestructuredArgument { identifier: "config", default: None, }, FunctionHeadDestructuredArgument { identifier: "lib", default: None, }, FunctionHeadDestructuredArgument { identifier: "pkgs", default: None, }, ], }, ), body: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "imports", span: Span { start: Position { line: 6, column: 3, }, end: Position { line: 6, column: 10, }, }, }, ), ], to: List( List { elements: [ Path( Path { parts: [ Raw( PartRaw { content: "../../profiles/base.nix", span: Span { start: Position { line: 7, column: 5, }, end: Position { line: 7, column: 28, }, }, }, ), ], span: Span { start: Position { line: 7, column: 5, }, end: Position { line: 7, column: 28, }, }, }, ), Path( Path { parts: [ Raw( PartRaw { content: "./sd-image.nix", span: Span { start: Position { line: 8, column: 5, }, end: Position { line: 8, column: 19, }, }, }, ), ], span: Span { start: Position { line: 8, column: 5, }, end: Position { line: 8, column: 19, }, }, }, ), ], span: Span { start: Position { line: 6, column: 13, }, end: Position { line: 9, column: 4, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "boot", span: Span { start: Position { line: 11, column: 3, }, end: Position { line: 11, column: 7, }, }, }, ), Raw( PartRaw { content: "loader", span: Span { start: Position { line: 11, column: 8, }, end: Position { line: 11, column: 14, }, }, }, ), Raw( PartRaw { content: "grub", span: Span { start: Position { line: 11, column: 15, }, end: Position { line: 11, column: 19, }, }, }, ), Raw( PartRaw { content: "enable", span: Span { start: Position { line: 11, column: 20, }, end: Position { line: 11, column: 26, }, }, }, ), ], to: Identifier( Identifier { id: "false", span: Span { start: Position { line: 11, column: 29, }, end: Position { line: 11, column: 34, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "boot", span: Span { start: Position { line: 12, column: 3, }, end: Position { line: 12, column: 7, }, }, }, ), Raw( PartRaw { content: "loader", span: Span { start: Position { line: 12, column: 8, }, end: Position { line: 12, column: 14, }, }, }, ), Raw( PartRaw { content: "generic-extlinux-compatible", span: Span { start: Position { line: 12, column: 15, }, end: Position { line: 12, column: 42, }, }, }, ), Raw( PartRaw { content: "enable", span: Span { start: Position { line: 12, column: 43, }, end: Position { line: 12, column: 49, }, }, }, ), ], to: Identifier( Identifier { id: "true", span: Span { start: Position { line: 12, column: 52, }, end: Position { line: 12, column: 56, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "boot", span: Span { start: Position { line: 14, column: 3, }, end: Position { line: 14, column: 7, }, }, }, ), Raw( PartRaw { content: "consoleLogLevel", span: Span { start: Position { line: 14, column: 8, }, end: Position { line: 14, column: 23, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "lib", span: Span { start: Position { line: 14, column: 26, }, end: Position { line: 14, column: 29, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "mkDefault", span: Span { start: Position { line: 14, column: 30, }, end: Position { line: 14, column: 39, }, }, }, ), ], default: None, }, ), arguments: [ Integer( Integer { value: "7", span: Span { start: Position { line: 14, column: 40, }, end: Position { line: 14, column: 41, }, }, }, ), ], }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "boot", span: Span { start: Position { line: 19, column: 3, }, end: Position { line: 19, column: 7, }, }, }, ), Raw( PartRaw { content: "kernelParams", span: Span { start: Position { line: 19, column: 8, }, end: Position { line: 19, column: 20, }, }, }, ), ], to: List( List { elements: [ String( String_ { parts: [ Raw( PartRaw { content: "console=ttyS0,115200n8", span: Span { start: Position { line: 19, column: 25, }, end: Position { line: 19, column: 47, }, }, }, ), ], span: Span { start: Position { line: 19, column: 24, }, end: Position { line: 19, column: 48, }, }, }, ), String( String_ { parts: [ Raw( PartRaw { content: "console=ttyAMA0,115200n8", span: Span { start: Position { line: 19, column: 50, }, end: Position { line: 19, column: 74, }, }, }, ), ], span: Span { start: Position { line: 19, column: 49, }, end: Position { line: 19, column: 75, }, }, }, ), String( String_ { parts: [ Raw( PartRaw { content: "console=tty0", span: Span { start: Position { line: 19, column: 77, }, end: Position { line: 19, column: 89, }, }, }, ), ], span: Span { start: Position { line: 19, column: 76, }, end: Position { line: 19, column: 90, }, }, }, ), ], span: Span { start: Position { line: 19, column: 23, }, end: Position { line: 19, column: 91, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "sdImage", span: Span { start: Position { line: 21, column: 3, }, end: Position { line: 21, column: 10, }, }, }, ), ], to: Map( Map { recursive: false, bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "populateFirmwareCommands", span: Span { start: Position { line: 22, column: 5, }, end: Position { line: 22, column: 29, }, }, }, ), ], to: LetIn( LetIn { bindings: [ KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "configTxt", span: Span { start: Position { line: 23, column: 7, }, end: Position { line: 23, column: 16, }, }, }, ), ], to: FunctionApplication( FunctionApplication { function: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 23, column: 19, }, end: Position { line: 23, column: 23, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "writeText", span: Span { start: Position { line: 23, column: 24, }, end: Position { line: 23, column: 33, }, }, }, ), ], default: None, }, ), arguments: [ String( String_ { parts: [ Raw( PartRaw { content: "config.txt", span: Span { start: Position { line: 23, column: 35, }, end: Position { line: 23, column: 45, }, }, }, ), ], span: Span { start: Position { line: 23, column: 34, }, end: Position { line: 23, column: 46, }, }, }, ), IndentedString( IndentedString { parts: [ Raw( PartRaw { content: "[pi3]\nkernel=u-boot-rpi3.bin\n\n[pi02]\nkernel=u-boot-rpi3.bin\n\n[pi4]\nkernel=u-boot-rpi4.bin\nenable_gic=1\narmstub=armstub8-gic.bin\n\n# Otherwise the resolution will be weird in most cases, compared to\n# what the pi3 firmware does by default.\ndisable_overscan=1\n\n# Supported in newer board revisions\narm_boost=1\n\n[cm4]\n# Enable host mode on the 2711 built-in XHCI USB controller.\n# This line should be removed if the legacy DWC2 controller is required\n# (e.g. for USB device mode) or if USB support is not required.\notg_mode=1\n\n[all]\n# Boot in 64-bit mode.\narm_64bit=1\n\n# U-Boot needs this to work, regardless of whether UART is actually used or not.\n# Look in arch/arm/mach-bcm283x/Kconfig in the U-Boot tree to see if this is still\n# a requirement in the future.\nenable_uart=1\n\n# Prevent the firmware from smashing the framebuffer setup done by the mainline kernel\n# when attempting to show low-voltage or overtemperature warnings.\navoid_warnings=1\n", span: Span { start: Position { line: 24, column: 1, }, end: Position { line: 60, column: 7, }, }, }, ), ], span: Span { start: Position { line: 23, column: 47, }, end: Position { line: 60, column: 9, }, }, }, ), ], }, ), }, ), ], target: IndentedString( IndentedString { parts: [ Raw( PartRaw { content: "(cd ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 62, column: 13, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 62, column: 15, }, end: Position { line: 62, column: 19, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "raspberrypifw", span: Span { start: Position { line: 62, column: 20, }, end: Position { line: 62, column: 33, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/share/raspberrypi/boot && cp bootcode.bin fixup*.dat start*.elf $NIX_BUILD_TOP/firmware/)\n\n# Add the config\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 65, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: Identifier( Identifier { id: "configTxt", span: Span { start: Position { line: 65, column: 14, }, end: Position { line: 65, column: 23, }, }, }, ), }, ), Raw( PartRaw { content: " firmware/config.txt\n\n# Add pi3 specific files\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 68, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 68, column: 14, }, end: Position { line: 68, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "ubootRaspberryPi3_64bit", span: Span { start: Position { line: 68, column: 19, }, end: Position { line: 68, column: 42, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/u-boot.bin firmware/u-boot-rpi3.bin\n\n# Add pi4 specific files\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 71, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 71, column: 14, }, end: Position { line: 71, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "ubootRaspberryPi4_64bit", span: Span { start: Position { line: 71, column: 19, }, end: Position { line: 71, column: 42, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/u-boot.bin firmware/u-boot-rpi4.bin\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 72, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 72, column: 14, }, end: Position { line: 72, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "raspberrypi-armstubs", span: Span { start: Position { line: 72, column: 19, }, end: Position { line: 72, column: 39, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/armstub8-gic.bin firmware/armstub8-gic.bin\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 73, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 73, column: 14, }, end: Position { line: 73, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "raspberrypifw", span: Span { start: Position { line: 73, column: 19, }, end: Position { line: 73, column: 32, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/share/raspberrypi/boot/bcm2711-rpi-4-b.dtb firmware/\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 74, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 74, column: 14, }, end: Position { line: 74, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "raspberrypifw", span: Span { start: Position { line: 74, column: 19, }, end: Position { line: 74, column: 32, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/share/raspberrypi/boot/bcm2711-rpi-400.dtb firmware/\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 75, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 75, column: 14, }, end: Position { line: 75, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "raspberrypifw", span: Span { start: Position { line: 75, column: 19, }, end: Position { line: 75, column: 32, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/share/raspberrypi/boot/bcm2711-rpi-cm4.dtb firmware/\ncp ", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 76, column: 12, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "pkgs", span: Span { start: Position { line: 76, column: 14, }, end: Position { line: 76, column: 18, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "raspberrypifw", span: Span { start: Position { line: 76, column: 19, }, end: Position { line: 76, column: 32, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: "/share/raspberrypi/boot/bcm2711-rpi-cm4s.dtb firmware/\n", span: Span { start: Position { line: 62, column: 1, }, end: Position { line: 77, column: 7, }, }, }, ), ], span: Span { start: Position { line: 61, column: 10, }, end: Position { line: 77, column: 9, }, }, }, ), span: Span { start: Position { line: 22, column: 32, }, end: Position { line: 77, column: 9, }, }, }, ), }, ), KeyValue( BindingKeyValue { from: [ Raw( PartRaw { content: "populateRootCommands", span: Span { start: Position { line: 78, column: 5, }, end: Position { line: 78, column: 25, }, }, }, ), ], to: IndentedString( IndentedString { parts: [ Raw( PartRaw { content: "mkdir -p ./files/boot\n", span: Span { start: Position { line: 79, column: 1, }, end: Position { line: 80, column: 7, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "config", span: Span { start: Position { line: 80, column: 9, }, end: Position { line: 80, column: 15, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "boot", span: Span { start: Position { line: 80, column: 16, }, end: Position { line: 80, column: 20, }, }, }, ), Raw( PartRaw { content: "loader", span: Span { start: Position { line: 80, column: 21, }, end: Position { line: 80, column: 27, }, }, }, ), Raw( PartRaw { content: "generic-extlinux-compatible", span: Span { start: Position { line: 80, column: 28, }, end: Position { line: 80, column: 55, }, }, }, ), Raw( PartRaw { content: "populateCmd", span: Span { start: Position { line: 80, column: 56, }, end: Position { line: 80, column: 67, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: " -c ", span: Span { start: Position { line: 79, column: 1, }, end: Position { line: 80, column: 72, }, }, }, ), Interpolation( PartInterpolation { expression: PropertyAccess( PropertyAccess { expression: Identifier( Identifier { id: "config", span: Span { start: Position { line: 80, column: 74, }, end: Position { line: 80, column: 80, }, }, }, ), attribute_path: [ Raw( PartRaw { content: "system", span: Span { start: Position { line: 80, column: 81, }, end: Position { line: 80, column: 87, }, }, }, ), Raw( PartRaw { content: "build", span: Span { start: Position { line: 80, column: 88, }, end: Position { line: 80, column: 93, }, }, }, ), Raw( PartRaw { content: "toplevel", span: Span { start: Position { line: 80, column: 94, }, end: Position { line: 80, column: 102, }, }, }, ), ], default: None, }, ), }, ), Raw( PartRaw { content: " -d ./files/boot\n", span: Span { start: Position { line: 79, column: 1, }, end: Position { line: 81, column: 5, }, }, }, ), ], span: Span { start: Position { line: 78, column: 28, }, end: Position { line: 81, column: 7, }, }, }, ), }, ), ], span: Span { start: Position { line: 21, column: 13, }, end: Position { line: 82, column: 4, }, }, }, ), }, ), ], span: Span { start: Position { line: 5, column: 1, }, end: Position { line: 83, column: 2, }, }, }, ), span: Span { start: Position { line: 3, column: 1, }, end: Position { line: 83, column: 2, }, }, }, )