Jump to content
InsanelyMac Forum
Guest BuildSmart

PCI Utils

Recommended Posts

Guest BuildSmart

For those looking for the pciutils, I have re-ported the applications and include the PCILib framework which provides a much better Darwin/MacOSX implementation.

 

Attached are 3 archives, the source for PCITools v2.2.9 software including the v2.2.9 framework, a universal installer for PCITools v2.2.9 and a universal installer for the newer PCITools v3.0.0 which at this time is not available anywhere but insanelymac.com.

 

The binaries have been compiled to work in 10.4.x and 10.5.x on Intel or PPC Macs and Hacks.

 

People reported issues with the binaries but no one reported any details of the crash so it is impossible to determine if the issue is their machine or the binaries but since I provided the source I don't understand why they didn't build and install it to see if the binaries are at fault, for those who don't know how to do this here are the commands on how, expand the archive in your home directory, open a terminal window and issue the following commands

cd PCITools-2.2.9; xcodebuild; sudo xcodebuild DSTROOT=/ install

and restart the machine.

 

I built and tested these binaries, all tests were reported on Core 2 DUO or better machines and I did not experienced any crashes.

 

I have re-uploaded everything so at this time, anyone experiencing any issues has probably got some hidden problem with their system cause I couldn't get it to crash 1 time on 11 different machines.

 

In case you don't know how a framework works, if you build the source you actually have to install it to test it because the applications rely upon the framework to do it's thing, and ownership/permissions is important and this is why I provided a binary installation to ensure they were built and installed properly.

 

NOTE:

Please don't send me any PM's unless you been invited to do so, I am not here to provide personalized support for free and there are other people here who can answer pretty much any question you might have.

 

If you try to build the framework and you experience an issue trying to load the extension without having the framework installed in it's destination it is clear you have no clue how linking or a frameworks works and should not be attempting to generate your own installation, use the provided binaries and save yourself from looking like a fool.

 

UPDATE:

updated pci ID's and lspci/setpci man pages to reflect Mac OS X installation options.

PCITools_2.2.9.tar.gz

PCI_Tools_v2.2.9.pkg.zip

PCI_Tools_v3.0.0.pkg.zip

Share this post


Link to post
Share on other sites
Advertisement

Thanks for the work! I was using the other OS X PCI Utils port from that other x86dev forum for OSx86 Tools, but I will see if I can update it to this version :)

Share this post


Link to post
Share on other sites

Funny toy!

Why we need it? To crash a system?

 

Old problem

sergey:~/Desktop/PCITools-2.2.9/build/Release root# kextload -v /Off/PCI*
kextload: extension /Off/PCITools.kext appears to be valid
kextload: loading extension /Off/PCITools.kext
kld(): /Off/PCITools.kext/Contents/MacOS/PCITools load command 2 unknown cmd field
kextload: kld_load_from_memory() failed for module /Off/PCITools.kext/Contents/MacOS/PCITools
kextload: a link/load error occured for kernel extension /Off/PCITools.kext
load failed for extension /Off/PCITools.kext
(run kextload with -t for diagnostic output)
sergey:~/Desktop/PCITools-2.2.9/build/Release root#

 

I resolve the problem with Joblo's pciutil (www.x86dev.org) which is the same.

Share this post


Link to post
Share on other sites
Guest BuildSmart
Funny toy!Why we need it? To crash a system?Old problem
sergey:~/Desktop/PCITools-2.2.9/build/Release root# kextload -v /Off/PCI*kextload: extension /Off/PCITools.kext appears to be validkextload: loading extension /Off/PCITools.kextkld(): /Off/PCITools.kext/Contents/MacOS/PCITools load command 2 unknown cmd fieldkextload: kld_load_from_memory() failed for module /Off/PCITools.kext/Contents/MacOS/PCIToolskextload: a link/load error occured for kernel extension /Off/PCITools.kextload failed for extension /Off/PCITools.kext (run kextload with -t for diagnostic output)sergey:~/Desktop/PCITools-2.2.9/build/Release root#

I resolve the problem with Joblo's pciutil (www.x86dev.org) which is the same.

You didn't resolve the problem, you can't even see that the problem is your build.From what I can see, you built the source and it doesn't work, you loaded with "-v" and you should have loaded with "-vt" to get a detailed description of the error and, the error I do see is a link error to libkld which means that libkld is missing or not installed on your system.I'm not going to hold your hand so you can build it properly, this you should be able to do all by yourself and instead of complaining that there is something wrong with the code maybe you should spend the time learning how to build i properly.
I used Joblo's one and it works great, although its version 1.0.1.
Advancement in functionality is a very good reason to upgrade the software, if you wanna build it yourself, make sure you know how to build it properly, just because it's an XCode project doesn't mean it's built properly just because you click the build icon.

Share this post


Link to post
Share on other sites
Guest BuildSmart

I received via e-mail some praise which details the improvements in functionality and flexibility in linking applications through the use of the PCILib framework.

 

When built and properly installed the framework allows for a greater environmentally compliant use of linking and does not suffer link issues normally experienced through the use of weak-linked libraries.

 

I'm considering the expansion of the framework and driver to expand the capabilities and functionality of the product.

 

If you are familiar with the IOKit framework, know how to use it, have a desktop computer and some time available then perhaps you can assist me with this project and we can expand it's functionality to include the ability make changes permament.

 

Once these changes have been implemented and tested we can provide the entire project as an open source project providing a useable base in which to further expand from.

Share this post


Link to post
Share on other sites
Guest BuildSmart

I was able to obtain the source for DPCIManager (thanks duddie) and in the next couple of days I'm going to rework it to use the framework and extract the data from the PCI slots rather than the registry which may not contain devices that are not listed in it as well as expand it to include the subsystem information.

Share this post


Link to post
Share on other sites
Guest BuildSmart
keep up the good work.
integrating the DPCIManager source is a pain however, the author has a nice grasp on the IORegistry and it's some of the nicest code I've seen from a nobody in a long time (of course it has it's areas of cruft but overall excellent IMO).

Share this post


Link to post
Share on other sites

let me use the opportunity to ask if there are any advantages of 'pcitools' compared to 'reggie'?

thank you

Share this post


Link to post
Share on other sites

Could you please provide the source for the 3.0.0 modifications (or did your changes to 2.2.9 apply cleanly to 3.0.0). I'd like to take a look at the changes made. Thanks.

Share this post


Link to post
Share on other sites
Guest BuildSmart
Could you please provide the source for the 3.0.0 modifications (or did your changes to 2.2.9 apply cleanly to 3.0.0). I'd like to take a look at the changes made. Thanks.
The source for 3.0.0 is not currently available, the patches wont apply but I will remove the custom library functions and apps I added over the next couple of weeks and provide the project source that builds the posted 3.0.0 binaries.

 

If you're only using the binary why do you need the source?

 

There seems to be a big push at this time to not release any source because people are under the impression that someone or some company is getting rich off of their work.

 

They see someone else getting money (not much mind you) and they want to be paid, they whine with that raped virgin look, they don't consider any expenses being incurred by the use of this software or the legal fees that are being spent due to it's use, they only see that they are not getting paid and someone else is so in retaliation they stop releasing software that the community can benefit from.

 

I personally don't care one way or another myself, I do know that no matter what you do, you cannot alter an existing license that source is released under so the yahoo's who think that they can take apple source and modify the license in an attempt to prevent commercial use are breaking the original license agreements and if they think they can close source their project but release a binary they are also sadly mistaken, the original license prevents this, if you distribute a work based on this source then the source must be made publicly available per the terms of the license, apple legal went to great lengths to explain this to me.

 

Another issue is when the author decides he no longer wishes to support a project, rather than open source it so it can continue to be worked on by those in need, the author denies you this leaving you stuck without a solution.

 

I have a small handful of people I pretty much give any of my own projects to and I release the ones I believe are beneficial, can I impose restrictions in licensing for usage, yes, do I bother, no, the gain is not worth the aggravation and that is my outlook on it.

Share this post


Link to post
Share on other sites
The source for 3.0.0 is not currently available, the patches wont apply but I will remove the custom library functions and apps I added over the next couple of weeks and provide the project source that builds the posted 3.0.0 binaries.

 

If you're only using the binary why do you need the source?

 

There seems to be a big push at this time to not release any source because people are under the impression that someone or some company is getting rich off of their work.

 

They see someone else getting money (not much mind you) and they want to be paid, they whine with that raped virgin look, they don't consider any expenses being incurred by the use of this software or the legal fees that are being spent due to it's use, they only see that they are not getting paid and someone else is so in retaliation they stop releasing software that the community can benefit from.

 

I personally don't care one way or another myself, I do know that no matter what you do, you cannot alter an existing license that source is released under so the yahoo's who think that they can take apple source and modify the license in an attempt to prevent commercial use are breaking the original license agreements and if they think they can close source their project but release a binary they are also sadly mistaken, the original license prevents this, if you distribute a work based on this source then the source must be made publicly available per the terms of the license, apple legal went to great lengths to explain this to me.

 

Another issue is when the author decides he no longer wishes to support a project, rather than open source it so it can continue to be worked on by those in need, the author denies you this leaving you stuck without a solution.

 

I have a small handful of people I pretty much give any of my own projects to and I release the ones I believe are beneficial, can I impose restrictions in licensing for usage, yes, do I bother, no, the gain is not worth the aggravation and that is my outlook on it.

 

As PCITools are GPL software you are obligated to publish the source code.

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.

  • Recently Browsing   0 members

    No registered users viewing this page.



  • Posts

    • salve a tutti ho questo laptop con ati hd 6370m, tuttavia la risoluzione non è corretta, sulle informazioni dice che ha solo 3mb di ram, qualche consiglio?
    • This is my first hackintosh Build.
      I installed windows 10 and made sure everything was working then
      i Change my bios settings. (See Below)
      I Created a [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url] usb with latest version of high Sierra 10.13.4 then installed it after erasing the whole drive
      Booted into MacOS then ran [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url] with these settings below then that when i Get the black screen after clover boot screen then i left the computer on and seems like it went into sleep mode because after i hit power after 15 mins Login screen was up.


      MOTHERBOARD
      GIGABYTE Z370 AORUS Gaming 5

      CPU
      Intel Core i7-8700K Desktop Processor 6 Cores up to 4.7GHz Turbo Unlocked LGA1151 300 Series 95W BX80684i78700K
      Graphics Card
      Gigabyte AORUS Radeon RX 580 8G 8GB GDDR5 256bit Graphics Card GV-RX580AORUS-8GD
      Cooling
      NZXT Kraken X62 All-in-One 280mm CPU Liquid Cooling System
      Ssd Hardrive
      Crucial MX300 1TB 3D NAND SATA M.2 (2280) Internal SSD
      Memory
      G.SKILL TridentZ RGB Series 16GB (2 x 8GB) 288-Pin DDR4 3000MHz (PC4 24000) 
      CASE
      Nzxt S340VR Elite Computer Case
      Bluetooth / WIFi (removed onboaard wifi and put this card)
      Broadcom BCM94352Z M.2 NGFF 802.11AC 867Mbps BT 4.0 DW1560 for Mac Hackintosh
      Power supply
      EVGA SuperNOVA 650 G3 650W 80 Plus Gold Modular Power Supply

      [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url] Settings Quick Start - UEFI Boot Mode Drivers Audio - Misc FakeSMC Plugins FakeSMC HWMonitor Application Network - Intel - Choose latest IntelMausiEthernet USB - Increase Max Port Limit 200 Series Bootloaders - Clover v2.4k r4063 UEFI Boot Mode + Emulated NVRAM Customize Graphics Configuration - AMD Graphics Fixup (required for AMD card!) System Definitions > iMac - iMac18,3  




      UEFI/BIOS settings After POST beep, press/hold DEL key to enter UEFI/BIOS Save & Exit menu - choose Load Optimized Defaults. MIT > Advanced Frequency Settings > Extreme Memory Profile (X.M.P) - choose Profile 1 BIOS Full Screen LOGO Show - I disable this, but not really required Boot Option Priorities - set this to the UEFI option for your UB flash drive. Disable all other choices. Once we run [url="http://www.insanelymac.com/forum/topic/279450-why-insanelymac-does-not-support-tonymacx86/"]#####[/url], we’ll come back in here and set to your new boot drive (in my case, the UEFI partition of Samsung 960PRO). CSM Support - Disable. Note that the Storage Boot Option Control option which is set to UEFI (desired setting) disappears along with the other 3 options under CSM Support when you set to Disable. Don’t worry, as Storage Boot Option Control apparently stays set to UEFI “under the hood.” Peripherals Initial Display Output - mobo should auto-detect your GPU card, so this should already show PCIe 1 Slot. You shouldn’t have to do installation using internal GPU, then switch to your GPU card. Peripherals > LEDs in sleep, Hibernation, and Soft Off States: OFF [this is optional if you don't want LEDs on 24/7, even in power-off state). USB Configuration > XHCI Hand-off - set to Enable Note: Once Thunderbolt3 AIC is connected, a new dynamic menu option for configuring the Alpine Ridge card appears below the USB DAC option (which lets you set options for USB charging on the appropriate ports). Chipset VT-D - Disabled Internal Graphics - Disabled (this also turns off the DVMT menu options). Wake on LAN Enable - Disable Power ErP - Enabled [UPDATE 25Mar2018] - This is now required to help fix issue where mobo on-board LEDs do not power off when in sleep/shutdown mode. Soft-Off by PWR-BTTN - I set this to Delay 4 Sec. Save & Exit - Choose Save & Exit Setup - this saves your changes and reboots your system.  
    • I've commited the actual code, later I'll make it as first example. Taken from edk2, I'm making this to work with: struct EDID_BLOCK { var Header : [UInt8] = [UInt8](repeating: 0, count: 8) //EDID header "00 FF FF FF FF FF FF 00" var ManufactureName : UInt16 = 0 //EISA 3-character ID var ProductCode : UInt16 = 0 //Vendor assigned code var SerialNumber : UInt32 = 0 //32-bit serial number var WeekOfManufacture : UInt8 = 0 //Week number var YearOfManufacture : UInt8 = 0 //Year var EdidVersion : UInt8 = 0 //EDID Structure Version var EdidRevision : UInt8 = 0 //EDID Structure Revision var VideoInputDefinition : UInt8 = 0 var MaxHorizontalImageSize : UInt8 = 0 //cm var MaxVerticalImageSize : UInt8 = 0 //cm var DisplayTransferCharacteristic : UInt8 = 0 var FeatureSupport : UInt8 = 0 var RedGreenLowBits : UInt8 = 0 //Rx1 Rx0 Ry1 Ry0 Gx1 Gx0 Gy1Gy0 var BlueWhiteLowBits : UInt8 = 0 //Bx1 Bx0 By1 By0 Wx1 Wx0 Wy1 Wy0 var RedX : UInt8 = 0 //Red-x Bits 9 - 2 var RedY : UInt8 = 0 //Red-y Bits 9 - 2 var GreenX : UInt8 = 0 //Green-x Bits 9 - 2 var GreenY : UInt8 = 0 //Green-y Bits 9 - 2 var BlueX : UInt8 = 0 //Blue-x Bits 9 - 2 var BlueY : UInt8 = 0 //Blue-y Bits 9 - 2 var WhiteX : UInt8 = 0 //White-x Bits 9 - 2 var WhiteY : UInt8 = 0 //White-x Bits 9 - 2 var EstablishedTimings : [UInt8] = [UInt8](repeating: 0, count: 3) var StandardTimingIdentification : [UInt8] = [UInt8](repeating: 0, count: 16) var DetailedTimingDescriptions : [UInt8] = [UInt8](repeating: 0, count: 72) var ExtensionFlag : UInt8 = 0 //Number of (optional) 128-byte EDID extension blocks to follow var Checksum : UInt8 = 0 } typealias EDID = EDID_BLOCK ...let you know
    • Wrong    No need to connect any TB device before booting the system. The TBEX 3 get's fully automatically initialised and implemented by OSX as soon a TB or TB XHC USB device will be connected to the already operational macOS system.   >>> https://youtu.be/JSNp75UOfq4 <<<   Give it a try with my SSDT-X299-iMacPro.aml properly adapted to your system    Full TB Hot Plug Functionality!    Maybe you also need an update to SMBIOS iMacPro1,1 in addition?   Cheers,   KGP
    • Hi @KGP-iMacPro, finally after more than a month some progress! Unfortunately this is not the definitive answer, but it poses other questions.
      What I did not say yesterday, is that once the THB_C cable is removed the Thunderbolt PCI card is not loaded by the system at startup. But if I have a device connected and turned on before boot the PCI card is recognized and loaded correctly, but not only, in this way you have the hotplug of all devices! To make it work, add "PCI-Thunderbolt One" to PXSX/BR1A. It works either with Arbitrary inject or with _DSM method on SSDT (better because the devices can be implemented on the PCI system info).   I use a Thunderbolt dock that turns on when I turn on the computer (to be precise, since I use Fix Shutdown, never turns off like my USB devices), and then the Thunderbolt PCI card is charged every time the computer is started and all the devices after the dock are hotpluggable.   Based on the original Apple SSDT of an iMac18,3, I realized this: SSDT-TB3 V3.zip (Updated version)
      However I do not know if it works correctly on both Thunderbolt ports and USB-C devices. I will do some more tests when we have the final solution.

      Obviously as I said, this is not a solution, but it makes clear that the problems with the hotplug derive from the functions that add the THB_C cable, so we are faced with two ways:
      1- Finding the way to make the PCI card load from the system even without a connected THB_C cable
      2- Understand what features this cable provides and whether it can be found in ACPI paths to include it in the SSDT    
×