Welcome to the Event Horizon

Wednesday May 28, 2008

Back in February, I wrote about the COMSTAR mptt port provider. Unfortunately, we weren't able or ready to release this code at the same time that COMSTAR was integrated into the Network Storage consolidation.

Due in large part to the relentless efforts of my manager, Sun has obtained the approval necessary to allow us to release the COMSTAR SAS port provider (mptt) into the wild (a.k.a. open source).

I am currently working (in my copious spare time) on getting all the pieces in place to get mptt integrated. In the meantime, as soon as I get a reasonable collection together, be it a tarball or what-not, I will post the source. As it stands right now, we are targeting July for integration of mptt. So, stay tuned for more information in the near future.

Tuesday Apr 15, 2008

My wife and I went to see My Chemical Romance at the Fillmore (Denver) last night. I've complained before about concerts that fall short of the mark in duration. Surprisingly, this was not one.

As is generally the case when you have kids, we left late enough to miss the first opening band and arrived just in time to catch the second. This, as it turns out, was unfortunate. I just don't get the allure of listening to guitars driven to near complete distortion and a lead "singer" who seems to be more at ease screaming all the lyrics. Maybe I'm old. Well, I am old, but I'm still here to see MCR.

Since I am old and I don't really care much for today's scream-band mentality, I'm not much of an MCR fan when it comes to the stuff prior to The Black Parade.

My wife had mentioned that she hoped they weren't going to ignore Black Parade and play all old stuff. I responded with "I bet they play at least 3/4 of The Black Parade". I was close. They played all but two songs and the "hidden" last track. I have to admit though, I enjoyed the older stuff much more than I did last time we saw them about eleven months ago. I was surprised that they played a set that lasted about 1:45. Now, I'm not saying that's great when you consider bands like Grateful Dead and Rush that would regularly push well past the two hour mark for every show. Compared to the wimpy 1h15m shows we seem to get from most bands these days, though, I'll take it.

Time to go get more coffee... Enjoy one of the few decent pictures I got with my cell's crappy digital camera.

Friday Apr 11, 2008

I had wanted to run audacity on Solaris for quite some time. The first time I tried to compile it was at least 18 months ago. It was a painful process that I quickly gave up.

Fortunately, things have come a long way since then. Getting audacity to compile and run on Solaris isn't a trivial process, but to be realistic, it's hardly trivial on any operating system. There are a lot of dependencies, and the size of that list depends on how much functionality you want. I will attempt to outline the path of least resistance.

First off, I do not work in the open source group here at Sun. I got peripherally involved in helping make audacity work on Solaris based on my personal interest. There are other folks that have done most of the heavy lifting in this area, and I'd like to thank them for doing so. I did, however, help tweak some of the patches as required to allow audacity to be compiled with SunStudio 11 and 12.

While I'm on the subject, you can build all of the required packages using either gcc or SunStudio 11 or 12. The trick is to make sure that all of the packages are built with the same compiler. If you wish to use gcc, be sure the env.[c]sh script in the CBE is setting all the environment variables correctly. In addition, I'd recommend building SFEgcc.spec and using that version of gcc for building any of the SFE packages.

In order to build audacity, you'll need the following:

  • A system running opensolaris
  • Either SunStudio 11 or 12 or gcc
  • The JDS CBE (Common Build Environment)
  • SFE (spec-files-extra)
  • OSS (Open Sound System)

Opensolaris

I will assume you already have a system running opensolaris, so let's move on.

JDS CBE

You'll want to install the CBE first, since you can use that to build and install gawk, which you'll need to build OSS. Pick up the latest tarball here. The instructions for building and installing the CBE can be found here.

One thing to note if you're running a recent opensolaris build. For example, in build 86 many packages were moved, renamed, or removed. I had to change the following in the cbe-install script in order for it to grab the right packages. Of course, I think they're right, but honestly I did this in a hurry and didn't try very hard to validate the changes.

OLD:

JDS_DEPENDENCIES="SUNWgpch SUNWi2cs SUNWi1cs SUNWi15cs SUNWceuos
    SUNWcleu SUNWeuluf SUNWdeiso1 SUNWi5cs SUNWi13cs
    SUNWi9cs SUNWeeuos SUNWi7cs SUNWesiso1 SUNWcleu2
    SUNWeu8os SUNWfriso1 SUNWale SUNWhkleu SUNWhleu
    SUNWinleu SUNWitiso1 SUNWjfpu SUNWkleu SUNWmeaos
    SUNWsmbaS SUNWnafos SUNWnamos SUNWneuos SUNWsamos
    SUNWseuos SUNWsviso1 SUNWtleu SUNWweuos SUNWgtar
    SUNWwgetr SUNWwgetu SUNWhea SUNWsfwhea
    SUNWsprot SUNWxcu4"
NEW:
JDS_DEPENDENCIES="SUNWgpch SUNWi2cs SUNWxwplt SUNWi15cs SUNWlang-cs
    SUNWcleu SUNWlang-en SUNWlang-de SUNWlang-fr SUNWlang-hu SUNWlang-pl
    SUNWlang-sk SUNWlang-common-extra SUNWlang-cs-extra SUNWlang-de-extra
    SUNWlang-fr-extra SUNWlang-hu-extra SUNWlang-pl-extra SUNWlang-sk-extra
    SUNWceuow SUNWi5cs SUNWi13cs SUNWi9cs SUNWlang-bg SUNWlang-bg-extra
    SUNWi7cs SUNWlang-es SUNWlang-es-extra SUNWcleu2 SUNWale SUNWhkleu
    SUNWhleu SUNWinleu SUNWlang-it SUNWlang-it-extra SUNWjfpu SUNWkleu
    SUNWlang-ar SUNWlang-es SUNWlang-da SUNWlang-sv SUNWlang-sv-extra
    SUNWtleu SUNWgtar SUNWwgetr SUNWwgetu SUNWhea SUNWsfwhea
    SUNWsprot SUNWxcu4"
Once the installation completes, be sure to modify your .profile, .cshrc, or whatever script you need to update to grab the environment from /opt/jdsbld/bin/env.[c]sh. You'll either need to do that or source the appropriate file prior to building anything with the CBE.

SFE

The next step is to checkout the latest files from the spec-files-extra repository at sourceforge. This can be done by running the following command:
svn co https://pkgbuild.svn.sourceforge.net/svnroot/pkgbuild/spec-files-extra/trunk SFE
from the directory in which you wish to put these files. You'll end up with a subdirectory called SFE inside of which will be various .spec files, patches, etc.

Once the checkout is complete, cd into the SFE directory and run the following command to build and install gawk:

pkgtool build --download SFEgawk.spec
Once gawk is installed, the next step is OSS.

OSS

Download the latest OSS tarball from here. As of this writing, the latest build was 1015. Follow the instructions on the RELNOTES.txt file for compiling and building the package. Once the package is installed, you may need to reboot in order to allow the OSS drivers to bind to your soundcard. If you're not sure whether you need to reboot, try running "osstest" after installing the package.

The first time I tried to install and use OSS, it was very difficult to install properly. I've found, though, that both builds 1014 and 1015 work quite well. My only real complaint is that the ossmixer application opens a window that doesn't even fit on my screen due to all the controls for the multi-channel soundcard. I also wish the volume control in xmms would control the mixer volume, but I admit I haven't bothered to see if there's a way to make that work.

Audacity

Last, and certainly not least, it's finally time to build and install audacity. You can do this one of two ways. You could just build and install every .spec file:
pkgtool build --download *.spec
in which case you might as well get yourself a mondo cup of coffee or go take a nap. Alternatively, you can build and install those packages that are necessary for audacity. If you ran "pkgtool build --download SFEaudacity.spec", you'd find it would fail indicating several dependent packages that had not yet been installed. To save you the trouble, at least with the current .spec files, this command line should suffice:
pkgtool build --download SFEogg-vorbis.spec SFElibsndfile.spec SFElibsamplerate.spec SFEportaudio.spec SFEfftw.spec SFEladspa.spec SFEladspa-swh-plugins.spec SFEsoundtouch.spec SFEwxwidgets.spec SFEaudacity.spec

If that's the case, you should see a message indicating that the build/install of all these packages was successful. Hopefully that's the case. If it isn't, fortunately pkgtool leaves detailed log files that should help you determine what went wrong during the build.

If all went well, fire up audacity and twiddle some bits.

Cheers.

Wednesday Apr 09, 2008

There's nothing like watching innovation occur, except perhaps being the one doing the innovating. Unfortunately, in this particular instance I'm watching. I'll take what I can get, though.

I thought it was pretty cool late last year when Radiohead announced that the intial release of their "In Rainbows" album was going to be via digital download. There's nothing innovative in providing digital downloads in this day in age. The innovative aspect of this was that the buyer could name their price. Download the entire album for whatever price you're willing to pay. It's probably safe to say that no major act had ever done that before.

To take things one step further, though, I got an email mid-last week indicating that Radiohead were making available five tracks via iTunes (like you need a hyperlink...). These five tracks comprised the quasi-individual tracks of their upcoming single release, Nude. The premise here is that fans can download each track, remix the song as they see fit, upload it to a provided site, and have it judged on by listeners. Again, I'm not sure I've heard of another band willing to release individual tracks to any of their songs. For $4.95, I was willing to take the plunge and see if I could manage a remix that didn't make me want to hide in a closet, much less be afraid to post it for review.

I did the remix using Audacity running on Solaris. It's nice to see musicians that aren't being stifled by the status quo in the recording industry. Golf claps all around.

If you're so inclined, the voting ends May 1st, and you can find my entry here. If you like it, shoot me a vote. I have no illusions of garnering enough votes to even capture anybody's attention, but it was a nice temporary diversion.

That reminds me, I'd tried for quite some time to get Audacity running on Solaris in the past. I was quite pleased to find out that it's now possible. I plan to describe how in my next entry which I promise will be much sooner than my blogging history might indicate.

Wednesday Feb 06, 2008

If you're reading this, you may have seen the recent announcement on the storage-discuss mailing list regarding COMSTAR and the fact that there is now support for a SAS port provider. In case you missed it, here is the thread.

There is also an opensolaris page that discusses the usage model for mptt.

There is one note that isn't mentioned in the mptt discussion link above. First off, if your SAS initiator is not another LSI 1068/1068e based HBA (Sun-branded or not), there is no need to read further. Second, if you already have a COMSTAR SAS configuration set up and are not having any issues discovering your COMSTAR LUs, then again, no need to continue unless it's simply for morbid curiousity.

OK. So, you are running SAS on COMSTAR, you're using a 1068 or 1068e based HBA as the initiator, and you're having trouble seeing the COMSTAR targets you've taken the time to create, register, and map. Fear not.

Now, I can't exactly explain why this seems to be a problem in some configurations and not in others. However, this change has fixed my configuration when I've run into this problem.

First question: Is your SAS initiator running on SPARC or x86 (x64)? Read the appropriate section below.

"Fixing" your 1068[e] initiator HBA running on x64 for COMSTAR

Fortunately, the HBA option ROM (BIOS) will allow you to make the necessary change.

Step 1: Reboot the system.
Step 2: Hit Ctrl-C when prompted to enter the LSI Logic Configuration Utility.
Step 3: From the main screen, choose your initiator HBA by highlighting the appropriate entry and hitting ENTER.
Step 4: Choose the "Advanced Adapter Properties" option and hit ENTER.
Step 5: Choose the "Advanced Timing Properties" option and hit ENTER.
Step 6: Look for the "Direct Attached Max Targets To Spinup" option. Chances are, the value there is going to be "0". Highlight that value and hit the space bar to increment the value. Choosing 8 should be reasonable.
Step 7: Hit ESC three times to get to the exit menu.
Step 8: Choose "Save changes then exit this menu" and hit ENTER.
Step 9: From the Adapter List (main) page, hit ESC, then choose "Save changes and reboot."

When your system comes back up, you should be seeing all of your COMSTAR LUs.

"Fixing" your 1068[e] initiator HBA running on SPARC for COMSTAR

For the SPARC initiator, you're going to need an LSI provided program called "lsiutil". If you've ever installed the LSI initiator driver (itmpt), you may have this on your system already. Look for /usr/bin/lsiutil. If you don't have it, you can get it here. Choose the "Solaris SPARC" download. You should end up downloading a file called SAS_Solaris_8-9_SPARC.zip or something similar. If you already have lsiutil, skip down to step 6 below.

Step 1: Download the file as referenced above.
Step 2: unzip the zip file into some subdirectory, then cd into that directory.
Step 3: You'll likely have a file called "itmpt_5.07.04_sparc.tar.Z", although the version number may be different.
Step 4: Extract lsiutil by doing the following: zcat itmpt_5.07.04_sparc.tar.Z|tar xf - install/ITImpt/reloc/usr/bin/lsiutil"
Step 5: As root, "cp install/ITImpt/reloc/usr/bin/lsiutil /usr/bin/"
Step 6: Run lsiutil
Step 7: Select the appropriate device from the available list and hit ENTER. If you are using the Solaris mpt initiator driver and you don't see any mpt ports listed, your version of lsiutil may be too old. If this is the case, you'll need to download a newer version from the link above. The current version at the link above is 1.52.17 (November 14, 2007) and it does work.
Step 8: Choose option 9. It may not show up in the list of options unless you hit "e" and ENTER, but you don't have to do that.
Step 9: At the "Enter page type:" prompt, type in 2 and hit ENTER.
Step 10: At the "Enter page number:" prompt, type in 1 and hit ENTER.
Step 11: At the "Read NVRAM or current values?" prompt, just hit ENTER for the default (NVRAM). You should see output similar to the following:

Enter page type:  [0-255 or RETURN to quit] 2
Enter page number:  [0-255 or RETURN to quit] 1
Read NVRAM or current values?  [0=NVRAM, 1=Current, default is 0] 

0000 : 22010803
0004 : 00000700
0008 : 00500230
000c : 00000000
0010 : 00000000
0014 : 00000018
0018 : 000a000a
001c : 000a000a

Do you want to make changes?  [Yes or No, default is No] 
Step 12: Type in Yes and hit ENTER to make changes.
Step 13: At the "Enter offset of value to change:" prompt, type in 8 and hit ENTER.
Step 14: Look at the value at offset 8 above. In this example, it's 00500230. If you see something like 00508230, you shouldn't need to change anything, and shouldn't be having a problem. Otherwise, you want to change bits 12 through 15. For this example, you would enter 00508230 and hit ENTER. That is, keep all the values the same except for nibble 3.
Step 15: At the next "Enter offset of value to change" prompt, hit ENTER to quit.
Step 16: At the "Do you want to write your changes?" prompt, type in Yes and hit ENTER.
Step 17: Hit ENTER to quit option 9, then hit 0 followed by ENTER and 0 followed by ENTER again to quit lsiutil.
Step 18: Reboot your initiator system.

When the system comes back up, you should see your COMSTAR SAS LUs.

If you have any issues relating mptt, device discovery, or even COMSTAR in general, feel free to send a message to storage-discuss.

Good luck, and happy SASing.

Thursday Sep 20, 2007

It has again been quite a while since I had a chance to sit and write. The last month or so has been crazy, but things are finally starting to settle down again.

I've now been back at Sun for just over a year. When I returned, I think everybody in a position to be concerned was well aware that I would have rather been coming back to write software rather than being an HBA engineer. Regardless, I came back into the Storage organization in an attempt to help build the new HBA engineering team. Since that time, this group has moved from Storage to Systems. I will soon be completing my tour of the three "S"es. Effective October 1st, I will be transferring from this group to work in the Solaris organization, once again as a software engineer.

For several months, I looked forward to the time when this change might occur. I've missed writing software, although I have had a couple of small opportunities to do so in this group. I've written software for as long as I can remember, so it was hard to be in a position where software was something that was written by others. Despite all this, I find myself still on the fence a bit about this change. In fact, I probably put both my current managers and my new managers through a bit of uncertainty while I tried to reconcile in my head exactly what it was I wanted to do.

The great thing about this group is that I've enjoyed working with all of these folks. It's hard to leave a group like that, even if you know that the people you are going to be working with is also good. I certainly learned a lot over the past year, being exposed to many facets of the engineering universe that pure software engineers rarely get a chance to see. In retrospect, I think that experience has only served to make me a better engineer. When your job is simply to write software, it's easy to neglect all the other groups of people who may not be directly affected by your work. Having a broader perspective is without a doubt a huge advantage.

Despite the fact that I am still a bit unsure about what I'm leaving behind, I am certainly excited about the opportunity to get back to what I love. Based on my experience over the past year, I have no doubt that the HBA engineering team as well as the entire product team will continue to thrive.

Wednesday Jun 20, 2007

Fear 1

Fear can easily elicit one of two basic responses in people. It can either cause you to shut down, or it can motivate you to step up to a challenge and meet it head on.

I've had many thoughts rumbling around my head lately, but when I sat down to write this, fear was the last one on my mind. As I started to turn this situation around, my first thought was going to be to write about certain circumstances that are causing a slightly different reaction in my mind; anger. However, it eventually occurred to me that fear was actually the basic motivator at work here.

I came to Sun the first week of 2004. Sun was to be the first big company I had ever worked for. Fear? You bet. Was I up for the challenge? It was a bit intimidating to think that this might be my biggest professional challenge. In retrospect, I believe it in fact was.

At this same time in early 2004, there was another person that came to start work at Sun. This guy was fresh out of college. It seemed obvious to me that he was somewhat intimidated coming to work here. Shoot, having never been in an engineering position before, I'm sure I would have been petrified. His first role here wasn't technically an engineering role, but after several months, it did evolve into one. In fact, at that time I was working on the Leadville stack primarily fixing FibreChannel bugs. This guy ended up working in the same group. I was tasked with being his mentor. Although Leadville was still fairly new to me, I was familiar with FibreChannel.

Being a mentor to a new engineer who was not familiar with kernel drivers, Solaris, or FibreChannel was a formidable task, but an enjoyable one. In fact, we quickly became good friends. We've both since moved on to different roles. I've left Sun and returned in a totally different capacity and he is now working in another part of the kernel. We remained good friends throughout all of this. I haven't had to do anything remotely akin to mentoring this guy for quite some time. In fact, I was extremely impressed with how quickly he was able to pick up debugging skills in the kernel as well as understanding a protocol as complicated as FibreChannel. In the past three and a half years, he has become in my opinion an extremely capable engineer.

All good things come to an end

As can happen at any company, talented employees can easily expand well beyond compensation that seemed adequate one day, but is wholly inadequate the next. Unfortunately, companies seem to have a great deal of inertia when it comes to things like compensation. When this friend of mine told me he was considering leaving Sun, I was admittedly angry. Why couldn't Sun just make things right? Did they realize what they were on the verge of losing? Well, it's not like this is the first time this sort of thing has ever happened. This is also certainly not a problem unique to Sun. It seems it's always a dance between employers and employees. Companies will invariably pay as little as they can in an effort to keep costs down, but it's always a gamble that they will lose valuable employees. I could be angry about this, but I think it'd be misplaced.

Fear 2

This time, I suppose the fear is not mine, but my friend's. He's leaving Sun to realize a hefty gain at a company that is going to provide a great deal of challenge to a junior engineer. That would definitely cause me some degree of fear, but I have no doubt he will rise to the challenge and continue to excel and grow as an engineer. In some respects, I envy him this opportunity. Things always have a way of coming around, anyway, so I have no doubt we will work together again at some point in the future. In fact, if there is ever an opportunity for him to return to Sun, it would be foolish for Sun to pass it up.

Until then, we all rock on in an effort to meet fear head on and prevail.

Tuesday May 01, 2007

They say these pages are here for us to write about anything we want, so I'll warn you up front that I have nothing useful to say today.

There are a few bands that I will make every attempt to see anytime they are in town. Cake is one of those bands. It's hard to classify what kind of music these guys play. You really just need to give them a listen. Perhaps you've heard one or more of their radio hits. The most likely candidates would be "Rock 'N Roll Lifestyle", "The Distance", "Never There", or "Short Skirt/Long Jacket". Cake has always been a hit in college radio circles, which makes their latest show here that much more interesting.

Cake played at the Coors Event Center at the University of Colorado in Boulder this past Sunday (4/29/07). There were a couple of unusual aspects to this show. We've seen them on a college campus before, but here's what struck me about this show.

First, this event was sponsored by CU students. That, in and of itself isn't so strange. What was strange, however, was that there was no alcohol served at the show. That was a definite first for me. I've seen a lot of concerts over the years, but I don't recall ever being at one where there was no alcohol. I have to wonder if this was common knowledge, because I've also rarely been at non-club type shows with so few people. Alright, well, even if I had known there was not going to be anything to drink there, I still would have gone. Like I said, I would never pass up an opportunity to see Cake.

The second thing that I wasn't prepared for at this show was lead singer John McCrea's apparent disdain for college students. Anybody that knows Cake, or more accurately, John McCrea knows that he's not shy about expressing his opinion. However, telling your loving, paying audience something along the lines of "This next song is from our latest album. Oh, wait... you guys probably don't know what albums are. You just download your music off the internet and fill up your shiny, expensive mp3 players for free". I'm not a college student, and I happen to own every Cake album, but OUCH. That still hurt.

John, quit playing games with my heart, dude.

Maybe I'm still harboring a grudge because I didn't win the autographed vinyl copy of Fashion Nugget from their recent contest. As if that weren't harsh enough, we were also treated to a beating based on the fact that most of the folks in the audience were probably about 10 years old when their first album came out. Probably true, too, albeit not for me. But then again, I certainly had no idea who Cake was in 1994.

Despite all of this, Cake are still my boys. Rock on, dudes. Here's their setlist from Sunday's show. Oh, wait, Cake doesn't play with a setlist. My bad. Here is the list of songs they spontaneously decided to perform on Sunday night:

Frank Sinatra
Rock 'N Roll Lifestyle
War Pigs
Stickshifts and Safetybelts                                                     
Comfort Eagle                                                                   
Wheels                                                                          
Love You Madly                                                                  
Comanche                                                                        
Shadow Stabbing                                                                 
Italian Leather Sofa                                                            
Mexico                                                                          
Guitar                                                                          
Haze Of Love                                                                    
Never There                                                                     
                                                                                
Encore:                                                                         
Short Skirt/Long Jacket                                                         
Sheep Go To Heaven                                                              
The Distance

Oh, and one last thing... Who decided that concerts that last a mere hour and a quarter were acceptable? You may be getting old, but so are we. If we can stand to have our feet stepped on by oblivious college students taking up twice their personal space dancing and have other inconsiderate slobs step right in front of you in an attempt to get six inches closer to the stage, the least you can do is play a decent length show.

I also wonder if their failure to play "Daria" was a deliberate slap in our collective faces. No worries, dudes. I'll just put on my Fashion Nugget CD that I bought.

-D

Friday Apr 20, 2007

Hello again. Long time, no blog.

It has been a busy couple of months in HBA engineering land as we approach a nexus on several projects. In the mean time, I've given a great deal of thought to what it means to me to be a software engineer. With a nod to Robert Hunter's first album in the title of this entry, I figured now was a good time to take a few minutes to wax on about software engineering and grinding code.

I've been writing kernel/driver software for about twelve years now. It's what I've wanted to do since the first time I poked around on a TRS-80 Model 1 back around 1981. I've been fortunate enough to be able to do just that to my heart's content until I took this role in HBA engineering in September, 2006. Without going into the gory details of just how I ended up in a position with essentially no code development, suffice it to say that I've been pining away since then in an attempt to get back to doing what I love. As the months have passed, though, I've come to a couple of conclusions.

1. Software engineering != grinding code

Yes, duh. I don't claim that this is some major revelation, but bear with me here.

There is a big difference between being a programmer and being a software engineer. I doubt any professional software engineer would dispute this, but I suspect there are plenty of software engineers that would be rather disheartened to have to give up writing code. It's always possible to remain a software engineer who writes code day in and day out if that is what gives your job meaning. Unfortunately, it's entirely possible, especially at Sun, that regularly writing code can be in direct conflict to my second conclusion.

2. I'm not sure what I want to do when I grow up

For the past 25 years, I've never once had a question in my mind about what it was I wanted to do when I grew up. Write code. I love code. I love diagnosing problems, analyzing core dumps, and fixing bugs in kernel code. That hasn't changed. What has changed, however, is that I've come to a point in my career where I now need to answer the question of whether I want to be a "programmer" or a "software engineer." At some point in any lengthy software engineering career, this question is likely to present itself. Do I want to write code forever, or do I want to eventually get to the level where I can get involved in more interesting, architectural-type work and solve larger problems?

I'm fairly certain that the answer to that question is that I want to advance my career and work with the minds that are solving the architectural issues that not only face the industry today, but will be facing the industry in the future. With that said, I need to resolve the issue of regularly writing code. I'm not sure if I'm ready to give up writing code. Perhaps I don't have to altogether, but it's not clear to me whether I'm reluctant to give up coding because I've done it for so long and I'm comfortable with it or if it's simply that I am worried about not being able to advance my career without giving it up.

It is obvious that these are questions I need to answer for myself, although I suspect there are plenty of engineers out there that have faced the same dilemma. I would love to read comments from anybody that has faced this or is facing this. Chime in. Give me your thoughts.

Until next time,

David

Saturday Feb 10, 2007

Happy Saturday evening.

As I've discussed before, I've spent most of my career being a software engineer. However, last September I returned to Sun after a short departure. When I came back, I took a role as the team lead for the HBA Engineering team. People ask what it is I do, and I often find it difficult to explain. I don't write software. I don't design hardware, although I am technically classified now as a hardware engineer. Regardless of what it is that I do, that's not the purpose of this discussion.

As an HBA engineer, I get a somewhat closer view of what's coming around the corner than I would have working as a software engineer. We have been involved with bringing SAS adapters to market since I came back to Sun.

I didn't think much about SAS at first, probably for two reasons. First of all, being brand new to the HBA engineering role, I was too busy trying to figure out what the heck my job really is. Second, it has taken a while to get "re-linked in" with the network at Sun. That's not to say I'm a player or anything of that sort, but the longer you're at Sun and the longer you're in a specific job at Sun, the more you inevitably become connected to people and projects at various levels within the company.

Now that I have had the time to become more connected as well as to figure out what it is I'm supposed to be doing, I've been able to see many of the threads that are enlightening me as to why it is that we're working on SAS HBAs.

Unfortunately, I can't discuss much of the detail surrounding our SAS strategy. What I can say, though, is that I am ecstatic to see that our strategy does, in fact map quite closely to that of other organizations within Sun. What we're going in this group is directly relevant to the overall success of other projects currently in progress in various areas of Sun.

I am ecstatic to come to this realization for a couple of reasons.

First, having spent nearly three years at Sun, this is the first time that I've been able to truly see the "Grand Unified Theory". There is a definite plan and I can actually see where what it is our team does from day to day fits into that plan. That in itself is exciting.

Second, what's even more exciting is the realization that what we hear about Sun's strategy is more than just the words. It's extremely encouraging to see both the strategy being discussed coming to fruition as well as the outcome of this work being reflected outside the company in terms of Sun's last quarter results. Obviously, folks outside of Sun are also starting to take notice.

I am still a relative newbie at Sun. I don't know how people who have been around for 5 or 10 or more years feel about what's currently happening. Perhaps regardless of where you've worked and for how long, the simple fact is that the older you get, the more cynical you become. It may be a good thing, then, that I'm not too old yet. Having worked many years at small companies, I've rarely seen enough worthy of any real interest. What's going on at Sun right now is what I consider exciting. The next couple of years will no doubt be extremely interesting within and outside Sun.

Don't worry too much. I don't sit around on Saturday nights thinking about what's going on at Sun. Unfortunately, it's Girl Scout cookie time, and my wife is the unit cookie director. She spends more time on her computer and on the phone during this time of year than I do. So, I hope you supported your local girl scouts and bought some cookies.

David

Tuesday Feb 06, 2007

I admit I am a Cake fan and member of their mailing list. Their website has an "Advice" section where readers try their hardest to get their brand of bizarre questions posted on the page and then (presumably) some Cake member tries their hardest to provide as witty and clever a response as they possibly can.

The latest newsletter from Cake indicated that we should check a link to find out how to win a few things, including a signed copy of their first album, Motorcade of Generosity on vinyl. I already own a copy on vinyl, but certainly not a signed copy.

It turns out that the way to win these items had to do with tthis week's advice column question which came from "Tim":

Question:

Dear CAKE,

I think a similar question may have been posed before, but how do you continue to enjoy life in this age? Knowing people across the world want to kill you, and that every time you turn the key to your car you're using a non-renewable resource that's not only destroying the environment but slowly destroying civilization? I'm 18, what do I have to look forward to in the grand scheme of things? Do any of you have families? What do you think about having kids? This may sound kind of desperate, sorry. I don't mean it to. I'm not really agonizing about it, but it's in the back of my mind a lot.

Thanks,

Tim

and the answer provided was:
Answer:

Tim

Excellent question Tim, and one that CAKE ADVICE would like to turn over to our valued website visitors. Please send your advice for Tim to cakeadvice@yahoo.com. Whoever writes the best advice for Tim will receive: The new limited edition CAKE "Rarities" CD, a t-shirt from the CAKE STORE, and a signed vinyl LP of our first album, "Motorcade of Generosity." All entries are appreciated.

Now, I suspect my chances of winning are rather slim. I doubt I'm witty enough. I am going to post my response here, though, because I do feel strongly enough about it, even if strength of will doesn't get me a signed LP.

Hi Tim and Hi Cake,

These questions burn in the backs of the minds of many of us from time to time. It's not a sign of desperation. It's a sign of the promise of humanity that we worry about such things. I find it especially encouraging that there are 18 year olds pondering these issues. That in itself gives me hope.

I suspect if you were living 10 years ago, or 100 years ago, or even 1000 years ago that these questions would still plague you. Is there anything special about our situation today that lends credence to the worries that humanity is on the brink of collapse? Probably not. So, with that in mind, let's work backwards on your questions.

First of all, I have a wife and four kids. After reading an article about global warming just a few days ago, I was rather down at the fact that I'd brought four children into a world that could potentially be incapable of sustatining life even within their lifetime. I mentioned this to my wife, and her argument is the same one I've used numerous times in the past and will bring to bear here as well. It is the obligation of folks like you and I to have kids. Humanity has a knack for surviving despite the short-sighted and sometimes seemingly evil decisions and actions of those in a position of power. This penchant that people have can only be strengthened by a new generation that share these values.

What do you have to look forward to in the grand scheme of things? What do any of us have to look forward to? We look forward to the things that give life meaning.: Family, friends, and the ability to do the things we do to make the world a better place for those that follow. This leads into my answer for your first question. Whether or not you are capable of enjoying life is highly relative. Some people are predisposed to see the negative aspects of life. Others see the positive. Where you lie on this curve strongly affects whether or not you can enjoy life. The short answer is that enjoyment is what you make it, and only you can answer that question. Do you need to ignore the issues that caused you to write to Cake for their sage advice? Of course not. Denying reality is not the answer.

Make the choices in this life that you feel are right. Understand that your sphere of influence on this world is limited. To some extent, enjoying life involves coming to terms with the fact that you cannot fix everything. Take some solace in the fact that you are not alone. We are all doing these same things. Perhaps together we can make a big enough difference to ensure that our kids and their kids can continue to enjoy this life.

Cheers,

David Hollister

Wednesday Jan 31, 2007

It's been quite a while since I've had a free minute in a day to write about anything much less a free minute to come up with something interesting enough to write about. In fact, I think it's pushing three months now since my last entry. Work has been absorbing practically my entire life since then, but you aren't here to read about that (I hear the sigh of relief). In fact, it's probably been pretty much the same for a lot of us here. I suppose that's as good a segue as any into the topic on my mind this evening.

There are always so many choices to make. Every day. Every email you get. Every phone call you take (or don't take for that matter). Every conversation with your boss, your co-workers, your family and friends. None of this is revelatory, I'm sure. The reason I mention it, though, is that you really get to know somebody more based on the choices they make than by any other means.

Some people really don't spend a lot of time fretting over how the choices they make are perceived by others. On the other end of that spectrum is... well... me, quite frankly.

For as long as I can remember, I've always been overly conscious of how choices I make or things I say or do (or don't do) may affect those around me or how they may be perceived. As I got older, I kept telling myself that perhaps I should worry less about those things and worry more about making choices that were right for me without as much regard for whether or not those choices would be looked upon favorably by others.

Unfortunately, or perhaps fortunately, I haven't been able to veer much from that state of being overly self-conscious despite all those years of trying to convince myself that it's OK to make "selfish" decisions on occasion. I say "unfortunately" because I've spent a good number of years getting to the point in my career where I am today, where perhaps I could have achieved this in far less time had I been a more aggressive advocate for myself.

On the other hand, though, I say "fortunately" for perhaps the very same reason -- that I am not only overly self-conscious, but am also overly *conscious*. I seem to have no choice but to over-analyze and dissect everything that everybody else says and does. What I see on a regular basis makes me wonder what would happen if *I* had said or done what this other person just said or did.

I suppose I'll never get beyond the over-analyzing, overly self-conscious persona that I've grown up with. At the end of the day, at least I decide that I can live with myself. That's about all I can hope for.

Saturday Nov 04, 2006

In the past few weeks, I've mentioned a particular observation to various people. That observation has to do with how work always expands to consume all available time. It was meant as a somewhat humorous anecdote, perhaps a response to a generic greeting along the lines of "Keeping busy?".

Perhaps I should qualify that statement a bit, because despite my arguable attempt at humor, I believe there is some truth to it.

"For the motivated professional, work expands to fill all available time"

I suppose that is better. It's good enough for now, anyway.

The point is that staff engineers are generally given a great deal of responsibility. Along with that responsibility comes an obligation to fulfill numerous expectations, well beyond what is expected of more junior engineers.

I try to keep up with my manager's blog entries largely because I feel that he and I have very similar ideas about what it means to work at or above the staff level. His perspective tends to bend toward the management side as mine will toward the technical side, but as our thoughts are well aligned, our perspectives tend to align in multiplicative ways.

My biggest complaint of late is the fact that I tend to spend as much time dealing with technical issues as I do with non-technical ones. I won't qualify that any further for various reasons, but it's the root of my expanding universe concept. One of a staff engineer's responsibilities is to guide and aid junior engineers. I don't take that lightly, even if it does consume a fair amount of time. In fact, I enjoy it. It's hard to qualify how something can simultaneously be the cause of a complaint and yet be something I enjoy doing. That qualification is the expanding universe.

Given enough responsibility and being of the mindset that generally guides engineers to a staff level or higher, the universe can quickly and regularly expand beyond your comfort level. The case in point is the fact that I have my laptop on today, Saturday, as I monitor email and compose this blog entry. There is a soccer game to go to later and I'm playing the lone parent today while my wife is out. On that note, it's time to turn off the tap on that universe.

Enjoy your weekend,

David

Friday Oct 20, 2006

Hey now,

A couple of weeks before I moved to Colorado to start working for Sun, I went to see acoustic Hot Tuna perform in Scottsdale, AZ. I was living in the Phoenix area at the time, and had a couple of buddies that were at the show, taping it none-the-less. I used to tape concerts, too, but that was a long time ago. At least I got a copy of this show, though. It was a good one, too, by the way.

Between songs, somebody from the crowd yelled, "Jack! You da man!". The rowdy concert-goer was giving his own shout out to Jack Cassady, the bass player. Mind you, this show was happening at a place called "Venue of Scottsdale", which was formerly known as "The Cajun House" for those who might be familiar with the concert/club scene in the east valley. Suffice it to say that this place may have held a few hundred people if it was packed, but on this particular night there were probably no more than 150 people in attendance. I was standing roughly 20 or 30 feet back from the stage. Without missing a beat, Jorma (the guitarist - amazing in his own right) responds "He is the man".

Up until early this week, I spent the vast majority of the previous two weeks trying to root cause a bug in a storage driver I'd never looked at before for a technology I have never worked on before (SAS). This is a somewhat maddening position to be in as all eyes turn to you for answers and you're just beginning to understand the question.

As if I haven't digressed enough yet, let me do so again. As folks like me (if there really is any such thing) are wont to do, we often ponder the meaning of our existence. Let's face it. As engineers, we exist in the hopes that someday, somehow, we're going to develop something that's so revolutionary, so earth-shatteringly brilliant, so cool that engineers we generally look up to in envy will think to themselves, if even for a moment "Wow, that's pretty cool. Why didn't I think of that?" Really, what else is there to live for?

Well, after 38 years on this planet (as of today, thank you very much), I've long since come to the realization that this sort of paradigm-shifting, envy-evoking, brilliant gem of engineering is not very likely to emerge from the likes of me.

That's ok.

Really.

Perhaps it's just a sad rationalization of the meager existence of a faceless engineer at a big company, but after two weeks of struggling with this bug and countless emails and phone calls to other engineers in an attempt to get a grip on the problem, I finally nailed down the root cause. My boss had been after me every day, if not numerous times a day asking for status. I walked over to his office and he asked me "Do you have good news for me?" (We need good news on a regular basis). I told him that indeed, I did have good news, that I had finally discovered the root cause of the driver bug. His immediate response was to point at me and say, "You da man!"

You know what? I am the man. Maybe it was just for a few seconds, but that's also ok.

Really.

And hey, there's always tomorrow to come up with that paradigm shift.

Cheers,

David

Friday Oct 06, 2006

Greetings,

During my recent five month stint at another company, I got into a debate with one of the long-time software engineers about code style. I was in the midst of working on a Linux video driver and had made some changes that I wanted him to have a look at. He made an off-hand comment about how I could feel free to change anything I wanted (he had written the driver I was working on). I responded that, while I'd like to change the way the code is formatted, I didn't see any point in doing so. It was just that the code was difficult to read.

One could hear the proverbial gloved hand smacking the face.

Alright, so it wasn't a knock-down, drag-out WWF style discussion, but I remembered the conversation yesterday while I was doing something I haven't done at Sun for quite some time; looking at code.

This is a great illustration of the topic we discussed (this code is freely available if you know where to look):

   int ret, field, size, count, nbfrs;
   VidDevice *vid;
   VbiDevice *vbi;
   V4LDevice *pp;
   printk(KERN_INFO AMD_VERSION "\n");
   pp = kmalloc(sizeof(*pp),GFP_KERNEL);
   if( pp == NULL ) return -ENOMEM;
   memset(pp,0,sizeof(*pp));
   strncpy(&pp->name[0],DRVNAME,sizeof(pp->name));
   pp->name[sizeof(pp->name)-1] = 0;
   pp->debug_level = debug;
   pp->irq = irq;
   lx_dev = pp;
   DMSG(1,"\n");
   vid = &pp->vid;
#ifdef CONFIG_PROC_FS
   lx_dev->proc = proc_mkdir(PROC_PATH,0);
   if( lx_dev->proc != NULL )
      create_proc_read_entry("video",0,lx_dev->proc,proc_lxv4l2_vid_read,vid);
#endif
   if( (ret=lx_init(pp)) != 0 ) return ret;
   if( (ret=vid_mem_init()) != 0 ) return ret;
   vbi = &pp->vbi;
   spin_lock_init(&vbi->lock);
   spin_lock_init(&vid->lock);
   vid->std_index = STD_SD_NTSC;
   vid->std_num = v4l_std_data[vid->std_index].num;
   vid->std_denom = v4l_std_data[vid->std_index].denom;
   v4l_default_capt_format(vid,&vid->capt);
   vid->capt_state = capt_state_idle;
   size = phys_bfrsz(vid->capt.sizeimage);
   count = v4l_max_buffers(size,vid);
   nbfrs = count - V4L_MIN_BFRS;
   if( nbfrs < V4L_MIN_BFRS ) nbfrs = V4L_MIN_BFRS;

There is nothing functionally wrong with the above code. (Well, maybe there is, but that's neither here nor there). In fact, the engineer who wrote the code was highly respected, even by me. However, just because a piece of code is functional doesn't mean it's "good". I mentioned that the code was difficult to follow. Said engineer responded that code shouldn't read like poetry.

The glove was now on the other hand.

I didn't come right out and disagree, but in my opinion that could not have been more wrong. It goes back to the "functional code != good code" argument. The fact that it took me significantly more time to understand the code due to the formatting was my reason for why it was not good code.

If you had a close enough look at the code above, you undoubtedly noticed many statements written in one line that would traditionally comprise multiple lines (look for the if statements). The other notable "feature" is the utter lack of whitespace. The engineer's rationalization for this type of code "style" (or lack thereof) was that "real estate is king". The more code that can fit on the screen at a time, the better.

I find it difficult to argue with that type of logic. Fundamentally, he and I are on different planes of reality. Anybody that writes code for a living must eventually come to understand that nobody owns a piece of code forever. Somebody else will no doubt be responsible for maintaining or extending your code at some point in the future. Personally, I'd rather not have a curse on my house for generations to come because I wanted to be able to see an extra five lines of code without having to scroll down. It seems to me this argument becomes even more salient when the code you write is visible by the entire world. The number of folks who would love to run into you in a dark alley late at night has now increased by several orders of magnitude.

What is it that makes poetry inherently interesting? It's a combination of the words that are chosen, the way those words are put together, and the underlying message being conveyed. In fact, even the way those words are presented on paper lends itself to the enjoyment of the work.

With all this in mind, how is software different from poetry? Good code is a combination of the same factors. An appropriate choice of constructs, the method used to compile the constructs into something cohesive, and how the way the code is presented allows for a rapid understanding of the problem being solved are higher contributing factors to successful software than how many characters you can squeeze into a window.

Suffice it to say the denouement was less than satisfactory. I am no more likely to convince someone that software is very much like poetry than I am to swim the English Channel. I take solace in the hope that I am not the only one that believes in software as poetry.

Cheers,

David