I want to remove the wireless NIC and Bluetooth devices from the .dtb I'm using

Hello,

As the title says, I am trying to modify my .dtb I am using to remove the wireless NIC and Bluetooth capabilities completely. I am currently using dtc, I was able to decompile to a .dts and use a text editor to remove the sections for bluedroid, bcmdhd_wlan, and bcmdhd_pcie_wlan. When I use dtc afterwards to try and recompile this to a dtb I get a slew of errors. I was wondering if anyone has some resources they can point me to for accomplishing this correctly as I’d rather learn than just be given the answer. Though, if I still can’t figure it out I would be happy to work through it and post all the commands run and errors that were spit out.

There is a “status = okay” line. Have you tried changing it to “status = disabled”, but otherwise leaving the entries in place?

No, I’ll give that a go.

Actually, before I try that I want to make sure. I want these to not even show up as an option after boot, would doing “disable” achieve that effect? To meet compliance, it has to be like the Wireless NIC and Bluetooth aren’t even there.

This I cannot answer. However, if you were to put in other measures, then this measure would have to first work. I think this might be one “ingredient” even if regulatory compliance needs more.

Incidentally, removing a device tree node is likely not different than disabling a node so far as compliance goes.

Bumping to make sure this doesn’t close, will provide logs next week when I can get back to the system I’m working on.

Disregard, I figured out my issue. I was getting way too hung up on error messages when using dtc for decompiling and recompiling the dts and dtbs. If you find this and are struggling it was as follows.

  1. find the .dtb your .conf uses when you’re flashing, decompile it with device tree compiler into a .dts, use a text editor to remove the lines you want. For me it was just removing the following:

};

bluedroid_pm {
	avdd-supply = <0x26>;
	dvdd-supply = <0x12>;
	compatible = "nvidia,tegra-bluedroid_pm";
	id = <0x0>;
	bluedroid_pm,reset-gpio = <0x1b 0x3d 0x0>;
	bluedroid_pm,host-wake-gpio = <0x28 0x3c 0x0>;
	bluedroid_pm,ext-wake-gpio = <0x1b 0xa4 0x0>;
	interrupt-parent = <0x28>;
	interrupts = <0x3c 0x1>;
	linux,phandle = <0xe6>;
	phandle = <0xe6>;
};

bcmdhd_pcie_wlan {
	compatible = "android,bcmdhd_pcie_wlan";
	interrupt-parent = <0x28>;
	interrupts = <0x3b 0x14>;
	wlan-pwr-gpio = <0x1b 0x68 0x0>;
	fw_path = "/vendor/firmware/fw_bcmdhd.bin";
	nv_path = "/vendor/firmware/nvram_4359_b1.txt";
	status = "disabled";
	linux,phandle = <0x171>;
	phandle = <0x171>;
};

bcmdhd_wlan {
	compatible = "android,bcmdhd_wlan";
	interrupt-parent = <0x28>;
	interrupts = <0x3b 0x14>;
	wlan-pwr-gpio = <0x1b 0x68 0x0>;
	fw_path = "/vendor/firmware/fw_bcmdhd_4354.bin";
	nv_path = "/vendor/firmware/nvram_quill_4354.txt";
	sdhci-host = <0xd7>;
	pwr-retry-cnt = <0x5>;
	status = "okay";
	linux,phandle = <0xe5>;
	phandle = <0xe5>;
};
  1. Make sure you’re not leaving any extra spaces or anything for what is above or what follows, save, recompile with dtc into a .dtb.
  2. Take that new dtb and drop it into the directories that the previous one you used are in, this was 4 different directories for me.
  3. Edit your .conf to use that new .dtb instead of the previous one.
  4. Flash that jawn, I was flashing a fresh image so make sure you check your documentation for flashing specific partitions.

@linuxdev I was not able to just disable them, they had to be removed completely. As always, thank you for your input.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.