Hi Pete,
Alright, you brought up some good questions and re-reading my previous post I can see that my description wasn't really clear.
Let me explain how I occasionally shut OFF cpu cores here. So my machine is AMD Phenom II X6 based box. 6 cores total, but when booting with 6 the WPS locks up at the blue-screen. So I have the 6th core disabled in BIOS and that allows me to boot up just fine. Never tracked this down, may have something to do with the motherboard having built-in video chipset, along with a few other things that my OS/2 configuratoin can not use.
Anyways, I boot up with 5 cores. Now, at times I need to shut off 4 of the 5 cores. For example, ANPM when started in full 5-core SMP mode will soft-lock the WPS, only CAD gets me out, but that's a system re-boot. So to avoid that outcome I flip to 1-core mode, start ANPM and the minute the window is built I flip back to 5-core mode. Again, haven't figured this out yet, tried playing with numerous approaches such as setting the EXE to SMP-unsafe, etc. I suspect somewhere on my machine is either a DLL, or perhaps a hardware setup that's the root cause.
To do this OFF/ON flip I use setproc.exe, which is a most handy utility by Yuri Dario.
Ok, so now let me answer below...
...If I understand you correctly this happened the first time you started PMsmartctl - you had not previously run PMsmartctl and set the location of smartctl.exe ?
As long as I am in the full SMP mode, so more than a single core active this always happens. Even after I manually edited the INI file and had the correct path to the smartctl.exe file, having re-started the program I still resulted in having a frozen non-responsive window.
The only time the app actually works is when I run in the limitted 1-core mode, as described above. So basically any other time I start it again, it will only work if I'm running in that 1-core mode, all other times it goes back to the soft-lock where just the app is non responsive. I can close it down with lSwitcher's Close=>Quit and do not have to use the harsher SIGKILL.
...I do not think there is anything that is SMP unsafe in the startup code but will have a rummage through to see if I can find possible cause(s). At first glance the only thing that stands out is that I have not explicitly initialised a couple of variables...
Hmm, good to hear that it is working fine on your end. It would trully be the icing on the cake if troubleshooting this issue would allow me to also figure out why full-core SMP mode here occasinally causes the problems I see. Right now my issue is limitted to impacting just your app, it does not lock up the whole WPS as it most often does with a handful of other apps I have.
...That could make a difference if there is some "garbage" in the location used for the variable smartctlPath as that would mean the check for smartctlPath having a value would return True which would then set the smartctlFlag indicating smartctl.exe was available triggering a call to "smartctl --scan" which could cause the startup problem...
OK, so on this subject I am curious about something. Once the path to smartctl.exe is provided the app continues to do something before I hit my lock. After all, the normally grayed out PATA and SATA fields do actually un-gray and I should be able to select which device I want to pull up the information for. So in your code the lock I see must happen after this point in time, which I'm guessing happens once smartctl (perhaps?) returns some valid list of devices maybe???
...I'll have to do a little bit of re-coding and post a new build a little later for you to try. Will also have a rummage through underlying OS/2 API calls made during startup to see if there is anything known to be SMP unsafe but I do not think there is...
Since we are in the coding forum, care to share your code? i ask b/c I pulled the source for smartmontools that Dave pointed me to. There is a specific OS/2 section in there (see os_os2.cpp and os_os2.h) which I am working throught right now to understand the differences between DANIS506 and OS2AHCI, I think I may have spotted something but I'm not quite sure yet. Given that your app does successfully allow me to pick one of my AHCI devices though would imply that your code at least knows how to differentiate between them and therefore must be issuing some call to determine what device is hooked to what controller. I'd love to see that code.
...Out of interest will PMsmartctl run with 4 cores enabled on your system?...
It runs, but goes into that non-responsive mode (I call soft-lock). Othewrise, only 1-core mode allows me to actually use it normally.