Rob's Blog rss feed old livejournal twitter

2017 2016 2015 2014 2013 2012 2011 2010 2009 2008 2007 2006 2005 2004 2002

February 7, 2018

Decided to drive the car back to austin this weekend rather than next weekend (of course more snow is coming), and Southwest screwed up so badly I've cancelled my "Rapid Rewards" account.

I tried to use my $144 flight credit from cancelling my return trip from ELC last year (since Jeff flew me straight to Tokyo from the west coast), and the site barfed because it expires tomorrow. Called customer service and it turns out you have to _complete_ travel by the expiration date, not just book it. (That would have been good to know.)

They suggested I call another customer service to see if they could make an exception (since I'm trying to book travel for sunday to fly back from Austin to Milwaukee, it's an extension of 3 days). And after half an hour on hold the customer service drone tried to charge me $100 to _not_ help me. ("All I can do" was buy a six month extension, and then they started into a long explanation about how this wouldn't let me apply credit to the Sunday flight, but instead I would be mailed a new voucher. So why bring it up?.)

Meanwhile Expedia found a flight that's cheaper than Southwest would have been _with_ the $144 applied, so it's not actually a loss. But I am "this company needs to die" levels of disappointed in them right now.

Maybe I'll forgive them after six years. (Historically when my vindictive streak is triggered it tends to last an even decade, but... I don't really care about southwest enough to hold a grudge? They're just useless and incompetent. They lost the "most airlines suck but this one is good at getting a plane full of people from point A to point B for an obvious price" special regard I held them in, and since they _don't_ sell through the same site others do, why bother to go look at them specially anymore?

Hmmm, way back when I read articles on the history of the company and how they felt they were competing with ground travel rather than other airlines, so had to keep improving even when they already had a huge competitive advantage. (This is why I described them as proof you could get the contents of a greyhound bus airborne.) Ah-ha! Their founder retired in 2008. Add ten years for his residual influence to attenuate and all their policies to be replaced by corporate drone du jour industry average BS, and yes. Southwest is Just Another Airline now.

(Same thing happened to IBM after Lou Gerstner left. Sam Palmisano followed the roadmap Gerstner left for 5 years, then stepped down at the end of it, and handed off to a clueless corporate drone. Neutron Jack Welch at GE leaving has been bad for that company too. Corporations try very very hard to treat humans as fungible (any unique individual is a liability, you must break up with them before they can dump you and find an appropriately bland beige robot), and it's a total lie. Steve Ballmer was a boring punch-clock villain, not an Evil Mad Scientist like Gates. Apple with and without Steve Jobs is a totally different company, I'm aware that Ives is doing the Plamisano thing of running out the clock of residual inspiration Jobs left but it doesn't change the "10 years later you're kinda screwed" timeline. A conglomerate without a good CEO steering is in for a hard time.

It's a pity my 3 waves talk at Flourish never got the recording published (despite me poking them about it repeatedly for over a year). I should try again...

February 6, 2018

I didn't get to write the initmpfs patch over the weekend, or the new perl removal thing for arm, or something to fix the ORC dependency, or updated initmpfs stuff, or nearly as much toybox stuff as I wanted.

This weekend Fade was visiting. Last weekend I moved into a new apartment. Next weekend I drive to visit fade so she can use the car. The weekend after that I drive the car back to austin so it's not getting a $40 ticket every time it snows (on street parking isn't valid during DPS operations, I need to move the car... to _where_?)

And at the end of the day, after two 20-minute trudges through snow to do 8 hours of porting legacy code in a cubicle (Ubuntu in a vmware window on a windows machine with outlook) I'm too tired to do much. And I can't do the "get up early and program before work" thing because they schedule 8am or 9am meetings 4 times a week, setting the alarm for 6 is barely enough time to make the 8am meeting.

I'm hoping that _next_ month I actually get a weekend to myself.

Oh well, at least there are no cats. So I'm getting a _little_ done.

February 5, 2018

Politics makes me angry because there's a lot of "that's not the real fix" going around right now.

Any time you have a "two party system" your politics are broken. First past the post voting needs to be replaced with instant runoff and more of a parlaimentary system.

Capitalism served its purpose: it regulates scarcity we no longer _have_. Most of the scarcity we wrestle with these days is _artificial_, created by cornering the market and protecting entrenched (outdated) interests. An economy where 60% of the population is full-time farmers is very different from 2% farmers, and we have not adjusted. We still threaten people with starving and freezing to death, while 1% of the population collects 90% of the output.

Between solar power with battery walls, self driving cars, the green revolution, vertical farming, container homes, internet on everybody's cell phone... most scarcity is pretty darn _optional_ for first world populations right now. Yeah the future is "unevenly distributed" but a "moon-shot" style deployment (ala FDR's Tennesee Valley Authority) could get new insfrastructure everywhere in under 10 years. We've done it before, more than once! But instead we subsidize oil companies by billions of dollars each year so they can turn around and spend it on lobbying to keep the subsidies going. We spend more on defense than the next dozen countries combined, decades _after_ winning the cold war. The third world is likely to leapfrog the first in things like rooftop photovoltaic and TAAS ("transportation as a service") because they haven't got existing infrastructure to replace, so they're not throwing good money after bad maintaining expensive legacy infrastructure. (They already did this with cell phones.)

Bullshit jobs. Universal Basic Income. Billionaires cornering the market, the 1% at Davros... These are radical positions the same way that abolition and women's suffrage were radical a century ago. They are major societal changes whose time has come. (Even a lot of racism is economic scar tissue that continues once the original reasons are long forgotten. See also african slavery and the demand for malaria-resistant plantation labor 300 years ago...)

Unfortunately the old geezers on top of the current pyramid are terrified of change and will attack anything that challenges the status quo. Society advances when old people die. I am _so_ looking forward to the end of the Baby Boom. But then I'm generation X, waiting for Boomers to get out of the way is _our_ defining shared experience...

February 4, 2018

Dropping Fade off back at the Greyhound station, we walked to the Stone Creek coffee shop across the street from the bus place to hang out with laptops for a bit.

In theory the greyhound station is as far from work as my apartment, just in a different direction (west instead of north). That's part of the reason greyhound might be a better option than driving, I could go there friday after work and get on a bus to Minneapolis, then back sunday night.

In practice, work isn't open on sunday, and neither is the Pita Pit we were navigating to as halfway point. Milwaukee, outside in February, is really really really really cold, and a half hour walk in it is a lot less pleasant than a fifteen minute walk. Even with a break in the middle (which turned out to be at potbelly subs, which was open and warm). Fade may be used to this, but I'm not.

Finally got some time to poke at pending toybox issues. I noticed the crc32 command in ubuntu (in both the new ubuntu 16.04 I set up for work and in my netbook's 14.04, "dpkg-query -S $(which crc32)" says it's in the libarchive-zip-perl package which is disgusting but apparently commonly installed. My crc32 logic can spit that out, it's "toybox cksum -HNLP", so a simple NEWTOY(crc32) with NULL arguments and crc32_main() that sets toys.optflags |= FLAG_H|FLAG_N|FLAG_L|FLAG_P; before calling cksum_main()... and it doesn't work... because I forgot FORCE_FLAGS. (Using cksum's flags when cksum is disabled, they get zeroed unless forced.) Ok, now it works.

So I can trivially provide this as a new toybox command with just a couple new lines, except A) if there's no file ubuntu's crc32 exits immediately instead of reading from stdin (I'm gonna call that "their bug"), and B) it only prints the filename when there's more than one argument. That's a design decision: grep works that way, sha1sum doesn't. What's _inconsistent_ is that cksum always prints the filename.

I already added -N to cksum (the ubuntu one has no arguments, mine lets you select endianness, pre/post inversion, and whether to include file length in the crc). Teaking -N not display the length either makes sense. having -N also only print the filename if there's more than one argument is less obvious, but adding a seprate option just to disable that is kinda silly... (It's another one of those "the difference is too small to have an obvious right answer" things.)

Oh, another difference is that crc32 always outputs 8 bytes of hex data where mine won't include leading zeroes. I think mine is wrong, and I should fix that.

Hmmm, the "print name or not" logic is actually a little more subtle: cksum doesn't print the filename when there is no filename (zero args, reading from stdin). The ubuntu one does, toybox doesn't yet but should. So if crc32 decrements argc by one, then the logic matches up... EXCEPT then we depend on optc being signed (because optc == 0 becomes -1) and while it _is_ I'm uncomfortable with leaving open the possibility of optc changign to unsigned at some point in the future and breaking this. (Well, test suite entry should check it and regression test should catch it, but in the meantime it can be if (toys.optc) toys.optc-- which would also work with unsigned.

February 3, 2018

Hanging out in Tiny Apartment with Fade. Introduced her to the nearby grocery store, which is pretty much all I'd found in the area. Finally tried the Gyro place around the corner, which is pretty good.

I've been caffeinating pretty heavily during the week, and not having any during the weekend, so there were some unexpected Attack Naps on the new air mattress.

February 2, 2018

Fade's come to visit, trying out the Greyhound bus from Minneapolis to Milwaukee. Given the security theatre at the airports, the bus takes about as long as planes do, and it's got more legroom, wireless, and an outlet to charge a laptop. So we thought we'd give it a try.

My plan was to pick up my car after work, drive to the greyhound station, get a little programming done at the coffee shop across the street until her bus came in, then drive her to Target to get an inflatable mattress for The Tiniest Apartment. (I've been sleeping on the two stacked sleeping bags I brought with me in the car, and given how hard the floor is it's still noticeably unpleasant, so I needed to do that anyway.)

Problem 1: Milwaukee may be a very walkable city but _driving_ through it, in the snow and slush and a layer of salt congealed on the windshield and covering all the road signs and lane markings, is No Fun At All. I managed to turn the wrong way on a one way street _three_times_. (Also, half the streets are two way and half are multi-lane one way and the lane markings are identical even when you _can_ see them.)

Problem 2: her bus was delayed by 2 hours leaving minneapolis, for reasons I'm still unclear on (they had to find a new pilot).

Problem 3: The coffee shop across the street closes at 7 and I got there at 6, with Fade now expected to arrive at 10. Not worth setting up, really.

Wound up going to Target myself, then going on a Quest For A Food Place That's Still Open to bring her a dinner-like item. Downtown kinda switches off after work. (Luckily the McDonald's near the Target is 24 hours, and grilled chicken snack wraps are almost like food.)

Got zero programming done, though.

February 1, 2018

Stopped at a second starbucks to redeem my Free Birthday Thing, and they don't do it either. Something about corporate vs franchise stores. Gave up and uninstalled the starbucks app.

January 31, 2018

A message on lkml fiddling with initmpfs wondered why it checks that you don't set root= (I.E. "as there must be a valid reason for this check...).

Backstory time!

I didn't want to switch rootfs to tmpfs all the time because it uses very slightly more resources, and if you're overmounting it with a fallback root= filesystem anyway those are wasted. It's a tiny waste, but it would be there on every system, so the check.

The _proper_ check would be that you have an archive to extract into initramfs: if you're extracting an archive into initramfs then you're using initramfs as your root filesystem, and thus making it a tmpfs instead makes sense.

Unfortunately, for years the default output of was three lines or so that created a /dev directory and a /dev/console entry. It was meant as example code, but when you didn't specify initrams contents it wound up getting called with no arguments and the build would create a tiny (150-ish byte?) cpio archive with /dev/console, and gzip it up. So initramfs would have a /dev/console in it, and then get overmounted and ignored.

And then the init/main.c logic grew a _dependency_ on this /dev/console. When opening stdin/stdout/stderr for pid 1, it basically called the open() syscall in the new process context with /dev/console, before pivoting out of initramfs. It worked because it was there, and then when it STOPPED being there (because I pointed out the default output and they fixed it) your initramfs wouldn't have stdin/stdout/stderr so they added a gratuitous mknod in initramfs context.

This feeds into the devtmpfs_mount patches, where right now there's a kernel config option to automagicaly mount devtmpfs when the system comes up, which ONLY applies to the fallback root= and not to initramfs. So I have a patch to add support, which is necessary if you create an initramfs by pointing the kernel souce to a directory of the initramfs contents as a normal user: It's the simple straightforward thing to do, but doesn't automatically add /dev/console and you can't create the device node as a normal user.

While I was there I cleaned up the kernel config stuff so you can tell it all the curent user's files should belong to root in the initramfs. Why nobody did that before I couldn't tell you, you had to specify which uid to map meaning your config had to know gratuitous details about your build system.

Anyway, I remember how somebody had a problem because their cpio.gz filled up more than half their ram and it failed with initmpfs but worked with initramfs. (Due to 50% of total memory being the default tmpfs size limit, so it filled up during the extract and stopped extracting.) I don't remember if lkml was copied on the email exchange but it resulted in this blog entry from the affected party.

Meaning I need to be able to specify "no really, rootfs should be ramfs" unless I can pass through size= to tmpfs options, or otherwise there are real world failure cases that hit existing people.

Unfortunately, some people clearly still don't get it. (Those are instructions for copying your initramfs into a tmpfs mount and then doing switch_root. My patches to let rootfs _be_ a tmpfs were merged in 2013.)

January 29, 2018

I wrote a thing on hermetic builds. It's related to the shared library part of the toybox design page which came up when the bc guys want an external lib.bc file to implement bc -l and I said might as well make it a big string constant in its own file (or with some #include magic).

January 28, 2018

I should probably have a page somewhere of "classic links", on topics that I should remember to introduce people to. (I have a links page but it's old and doesn't have summaries. I tried to put a few on the kernel docs page I used to maintain but lot access to update that in 2011.

One is the "Resource Curse", which is the problem that if most of a country's income comes from something like oil revenue, the country's government doesn't need 99% of its people. If you can't strike for better conditions because your labor is neither the source of income nor the thing that income is buying (everything, including cheap labor, can be imported), you have no natural leverage over those in power.

This is why you get "oil oligarchies". Countries like Russia and Saudi Arabia that earn the majority of their income from oil tend to have zero respect for human rights because if a plague wiped out 99% of their population the ruling elite wouldn't necessarily lose any income or amenities.

This is one of the reasons people are fighting for basic income as we automate away entire sectors of the economy: a century ago more than half the population worked as farmers, now it's less than 1%. The service and transportation industries that replaced them are also being automated away. This isn't a new problem: the Luddite movement protesting textile factories automating away weaving jobs happened over 200 years ago. But the erosion of the bargaining power of labor during the lifetime of the Baby Boomers has led to a real possibility of a technology-driven Resource Curse where the government doesn't need the people because we've got solar powered factories delivering 3D-printed goods via self-driving drone, and less than 1% of the population has any work you'd notice stopping if they went on strike. The Boomers won't live to see this, but the rest of us might.

I'd love to set up a conversation between David Graeber and Clay Shirky where they talked about this sort of thing for an hour. I really want to hear what they'd have to say, because I've got nothin'. (Shirky's Looking For the Mouse talk and Graeber's Bullshit Jobs essay play off each other quite interestingly.)

A persistent problem is that rich people are insulated from the consequences of their actions by a cushion of wealth, so they can be DAMN STUPID. (Hence the libertarian fish tank filter issue.)

And the anti-global-warming people are the tobacco institute are the leaded gas defenders, there are some good writeups about how those are literally the same people moving from one think tank to another as the funding sources change over the years.

And writeups on how capitalism is all about cornering the market and creating scarcity...

Sigh. I do my own writeups sometimes, with links to other people's stuff, but they get buried and lost in this blog. Dunno where else to put them. I haven't had a regular column with an externally imposed deadline since The Motley Fool days. (And those old archives are buried too, even things that made quite a splash at the time...)

But really, there's stuff out there that people should already know. Most of them _don't_, and I should have a place to point them for backstory.

January 27, 2018

Packed out of my hotel room by the noon checkout, although my car's still in their parking lot at the moment. I meet the apartment manager at the new place at 6pm to move in there. (No furniture but I brought two sleeping bags and a tray table to put my netbook on. I should buy a folding chair, I wonder where would sell that if there's no Target around here?

I looked for a clean quiet room, in walking distance of work (about 15 minute walk) with a shower/stove/refrigerator (pity it's gas, but oh well) with controllable temperature, outlets and a lockable door. (Well, it was quiet when I was there, we'll see how it is long term but I have earbuds and can get earplugs.) This fits those critera, and is quite reasonably priced.

And it has NO CATS IN IT. I might actually be able to get through the rest of the toybox roadmap in a finite amount of time. We'll see.

I type this from a starbucks. Well, a sort of starbucks. It's a corner of the grocery store I found (Metro Market, 2 blocks from the new apartment and more or less on the way to work from there) that has INSTALLED a starbucks, which opens on the 31st. Until then it's a seating area. I'm all for it. (No outlets, phone battery's already dead, netbook's at 38%. The replacement battery Fade ordered is regular size, not the jumbo size ones which last a long time but stick out awkwardly in a way that means I've now broken two of them.)

I've mostly been reading and closing browser tabs. So much backlog...

January 26, 2018

End of my first week at Johnson Controls. It's nice, for a Fortune 500 corporation that's put me in a cubicle. I don't see a problem doing 7 months of this.

I found a broom closet for $575/month with most bills included (you can get really SMALL efficiencies if you try), signed all the apartment paperwork, and today got a cashier's check for the proprated first month. They say I can move in tomorrow at 6pm.

Heart still beating way too fast this evening. I gave up and bought some chicken and one of the steaks the grocery store had on sale. My hotel room has a kitchenette in it (it's a lovely place, which has apartments on the top two floors. I found this apartment by talking to their apartment people, and they got me something in another building they manage the next block over). A week of fasting seems long enough for now, maybe I can atkins for a bit.

I've read organized, detailed diet plans with Intermittent Fasting and Keto Protein Loads and really, I'm not good with this. I can manage "do this" vs "not do this at all" distinctions. I suck at exerting consistent willpower over regulation of amounts over long periods of time, I have other things to DO. So "not eating today", "not eating carbohydrates"... That's about the level of granularity I can manage.

Hmmm, maybe I should find a gym. These tend not to work for me, but I'm still establishing a routine here. Walking to work and back builds a little exercise into my day, so that's nice.

January 25, 2018

I've been more or less fasting for a week now (I'm 80 pounds over what I weighed in college, that's like 1/3 of my current body weight), but something's going weird this time. My resting heartbeat lying on the bed at night is over 100 bpm, that doesn't seem right.

I've been using caffeine as an appetite suppressant, which amounts to a diet monster energy drink and a 1.5 ounce piece of "driving chocolate" per day this week (which is like _two_ energy drinks worth of caffeine, and I eat it in small chunks through the day). But if I stop having caffeine arond 4pm and it's 9pm, shouldn't it have worn off by now? Hmmm...

Last time I did this I leaned heavily on McDonald's Side Salads (15 calories by themselves, still less than 50 with half a pack of vinagrette dressing), which was fine for the drive here but the closest McDonald's is like an hour walk from my hotel room.

On tuesday I found a can of "monster muscle vanilla" and had my 200 calories all at once (with actual protein), but it was that convenience store's last can, they haven't restocked, the grocery store I found doesn't carry it, and google is unhelpful. (Hipstercart claims they can get it from kroger, but the nearest kroger is halfway to Chicago so I'm not sure what they mean by that.) There isn't a Target downtown either.

Of course another thing that does this to my heart rate is food poisoning, and without the salads my digestive systems seems to have entirely shut down this time. I wonder if that's related...

Broke down and bought two scoops of the "chicken and gravy" stuff the grocery store had. Absolutely delicious, and let's see if that settles my system...

January 24, 2018

I've been fasting on this trip, by which I mean eating 15 calorie McDonald's "side salad" with 40 calorie vinagrette dressing (using half a packet). but at one stop I failed my saving throw vs free pie because if you ordered through the kiosk, you got a free apple pie. McDonald's is trying to turn itself into a giant vending machine with no humans working there, as predicted by the expanded version of my old three waves talk, where stage zero is an idea you haven't acted on and stage 4 is fully automated with nobody working there anymore. Neither is a "business" so I didn't write about them for The Fool way back when, but it's kind of the full life cycle. "Computer" used to be a job title people did. Telephone operators used to connect every call. Elevators had operators before they had buttons. Further back, every household used to spin and weave and sew its own clothing, grow and preserve its own food...

There was a display of farm statistics at the last rest stop heading out of Texas, neatly explaining why "basic income" is now possible: a century ago we had 60% of the population working on farms (and a century before that it was 80%), now it's 2%. It was an Oil! Oil! Oil! display touting Tractors! and Chemical fertilizers!, but along the way we had the "green revolution" with dwarf wheat quadruple food production with better plants, so either way a smaller fraction of the populace is now producing way more food. (Most corn isn't for humans, see also the circle of rice.)

This means, strictly speaking, we don't _need_ the work over 90% of the population does, as in we're not going to starve without it. (But housing! The construction industry employs 10 million people, that's about 1/4 of 1% of the population of the country, 2% to <10% is a lot of slush factor for "ok, maybe necessary". And yes, I'm glossing over the can of worms that is healthcare, given how utterly screwed up it is in the USA, but most of "healthcare" is a giant bloated insurance industry and about half the rest is an administrative bureaucracy engaging with said insurance industry. Googling for per capita statistics, between europe and the US I get 3 doctors, 10 nurses, 2 pharmacists, and 1 dentist per 1000 people. Altogether that's 1.6%, still plenty of slack in the <10% actually assumed necessary above.)

Add in the revolution in transportation brought about by containerization starting in the 1950's, internet and smartphones, and the ongoing advances in solar power and self-driving vehicles, and meeting the basic survival needs of people is likely to take a _very_ small part of a modern economy a decade or so from now. Our big growth industries are things like entertainment. (Most people would rather hang out with friends, but who has time or energy when life revolves around sitting in a cubicle pretending to work most of each day?)

The knee-jerk argument against basic income is we can't afford to feed and house people for free, but exploding prison population? No problem! QE/bank bailout? Of course! If 2008 made one thing clear, it's that modern money is completely made up, it's numbers in a computer that the rich and powerful can edit on demand by _trillions_ of dollars, their only constraint is making sure the rest of us keep believing in it, respecting it, and chasing it.

The theoretical problem with printing money is inflation, so you tax the excess money away. The actual problem with adding money to the system is it pools in the pockets of rich people, so you have to tax _them_, and they complain loudly, with entire think tanks tasked with lying ot make them look indispensably important.

Rich people claim they're job creators but they're not: supply comes from workers and demand comes from everybody buying stuff they want or need. Billionaires are gatekeeping middlemen. But even assuming they were correct, the "incentives" argument gets cut out by real world research showing Say's Law doesn't kick in below a 70% tax rate. And what's another billion to a billionaire except a way of keeping score? Compound interest says they can spend millions of dollars every day for rest of their lives and end up with more money than they started with. It _doesn't_ run out. Techie co-founders like Paul Allen and Steve Wozniak (or founders like Jim Manzi of Lotus 1-2-3 fame) quit at $100 million because at that point more doesn't MATTER, the interest buys you a new house each week. They never have to do anything _useful_ again in their lives.

The people who continue to actively accumulate wealth into the billions are either driven by something other than money, or think they're bidding on the Titanic's Lifeboats and can never be "rich enough" to sleep soundly. (This is a self-fulfillig prophecy when their own asshole behavior in pursuit of wealth is the disaster they expect to be sending torches and pitchforks after them someday.)

David Graeber wrote about BS Jobs, which are useless jobs that produce or accomplish nothing. Many other jobs are only mostly useless, a 40 hour work week with 4 hours of actual work is fairly normal. They're created to satisfy a capitalist society's need for people to be employed in order for the people to be valued members of society (I.E. "Productive members of society"_ without producing anything anyone needs. Then there's entire industries like Tax Preparation that defend themselves via lobbying or similar, but are completely unnecessary. (Your information's already been reported to the IRS, in sane countries there's a website or similar you go to that has all the forms already filled out. You don't have to pay hundreds of dollars to pointless middlemen bureaucrats.) I'm also reading about how underemployment of lawyers is the new normal. There are no "safe" jobs, and many of the ones with good salaries tend to involve a modern guild like the American Medical Association that restricts membership.

But automating away all the jobs isn't a _bad_ thing if you kill enough billionaire middlemen intentional bottlenecks to clear the way to provide basic income, with which people can find new things to do. Creativity is _helped_ by having free time/energy/flexibility to play. Steve Jobs and Bill Gates didn't start new businesses because their survival depended on it, both were supported by their parents well into their 20's. They wanted to move up and have an impact on the world. As Graeber said, 99% of people not doing anything useful with their time is no different than 99% working retail jobs at Sears before Amazon mail orders came from a robotic warehouse to your door by delivery drones.

This is the kind of stuff I muse about on long cross-country drives. We're waiting for the Baby Boomers to die off so we can reach the kind of post-capitalism future Star Trek predicated half a century ago, but which they're too old and set in their ways to ever believe could be real even with solar power and self-driving cars and smartphones. Our problem isn't famine, it's obesity. There's a _distribution_ problem, since 2008 we have a simultaneous problem of abandoned houses and homeless people, that says the way we choose to organize society _sucks_. "We've always done it that way" isn't helpful when the rules change.

I do worry about the resource curse: a government that doesn't need its people tends to suck for those people, who can't strike for better conditions. But staying with capitalism isn't going to fix that. Again, the real problems are political, not technological.

January 23, 2018

Had to set up a new xubuntu system, 16.04 this time (if work is _paying_ me to use something with systemd...) and the procedure is always changing. This time the way to get the scroll bars back is to edit /usr/share/themes/*/gtk-2.0/gtkrc (where in this case the * is Adwaita, that's the theme selected in settings->appearance->style) and switch "GtkScrollbar-has-*-stepper" from 0 to 1, and also to change the GtkRange-stepper-size to 13 (from 0). (In theory you can set it globally but in practice every xubuntu theme manually sets these, overriding the global setting).

Without scrollbar arrows, scrolling the display up or down a fixed number of lines requires fiddly litle movements with the mouse and isn't always possible at low screen resolutions. With the arrow, click once to go up one line. So naturally, ubuntu disables them.

The SH4 VoD system has shown up in Austin! In a way that required a signature to accept delivery. I am in Milwaukee. I'd have them forward it to Fade in Minneapolis so I can pick it up when I visit (only 5 hours away, longish but reasonable weekend drive)... except for the requiring signature for delivery part. Hmmm...

January 22, 2018

Made it to milwaukee, first day of the new contract. Reading printouts, waiting for IT to drop off a computer, listening to long "this is the project" lectures from multiple coworkers. Pretty standard so far.

Quiet time in hotel room afterwards, cat-free. Luxury. (I napped, due to all the fog I was up driving last night until 2am.)

I just did "diff -u <(git diff toys/*/fmt.c) <(diff -u fmt.c fmt2.c) | less" with malice of forethought, because I saw this and went:

$ git am 0001-Un-default-fmt-1-while-it-s-in-pending.patch
Applying: Un-default fmt(1) while it's in pending.
error: toys/pending/fmt.c: does not match index
$ git diff toys/pending/fmt.c tests/fmt.test | diffstat
 tests/fmt.test     |    7 ++++
 toys/pending/fmt.c |   76 ++++++++++++++++++++-------------------------
 2 files changed, 42 insertions(+), 41 deletions(-)

I should really finish that. I wonder if I left myself a blog entry talking about what I was doing... No I didn't. Gotta read the diff.

A failure mode when I get _really_ overwhelmed is having a half-dozen tabs in a console window somewhere recording the state of an ongoing cleanup, where the backscroll shows tests I'm running that need fixing, experiments I did against multiple versions, and so on. If my netbook reboots before I get to a good stopping point and write it down or turn it into proper tests that TEST_HOST passes, and then I don't get back to that particular command for a month, I often wind up just "git resetting" the file and losing days of work that it would be easier to just redo.

This is why I call it "swap thrashing". I realy hope to be able to flush some cache on this expidition, as well as becoming flush with cache. (Sorry, couldn't resist.)

Elsewhere, the debian sh4 maintainer is being very nice and sending Rich Felker and myself a pair of cheap taiwanese Video On Demand boxes that (can be made to) run sh4 debian, and when Rich was talking about tracking down the right adapter to hook up the serial console, I asked to be kept in the loop. This led to the following exchange which I record here so I don't have to type it again if it comes up in another context. :)

> As I said, it’s already pre-installed with Debian Wheezy. I tested both boxes.

I was talking about Rich's attempt to get a serial console.

Without console output the box provides an all-or-nothing canned distro that has to bring up a large chunk of userspace before you have any output. So if I upgrade the kernel from -rc1 to -rc2 and it has a problem with some driver halfway through, I never get to see how far the boot got. If I tweak musl and sshd didn't come up, all I know is sshd didn't come up. I can't rdinit=/bin/sh or rdinit=/bin/helloworld-static to see what _does_ work. If device tree version skew can't find the interrupt controller because they changed something and the real problem is I need to upgrade dtc now, I have no trail of breadcrumbs to track that down.

> Connect power, ethernet, wait a few minutes until the LED is solid blue.
> Then check your router/DHCP server which address the box received, then just:
> ssh root@$IP
> Password: root

Which means that if the kernel doesn't boot all the way through, successfully extract its root filesystem, get through its init scripts far enough to successfully configure the network, and launch a daemon against a working C library, all I know is "it didn't work".

I've fed cpio.gz to kernels that only had cpio.xz support configured in. I've seen upgrades introduce a kconfig guard symbol that switched off BINFMT_ELF. I've accidentally dynamically linked something I meant to statically link that the init script depended on. I've seen binutils version upgrades make it write an inappropriate instruction because now it needs --no-really-stop-it-with-the-vector-extensions in ./configure, if I can't see the illegal instruction printk during the kernel boot that would really not be fun to track down.

I've worked on enough "If I change anything, it either works or it doesn't with no diagnostic information in between" systems over the years to know I probably wouldn't poke at anything that brittle in a hobbyist context. It would go back on the todo heap and stay there because I'd be afraid to touch it.

Possibly I could try getting a netconsole working on a static address (although that's still pretty iffy about early boot messages, many moons ago there was some work to create interruptless network driver stubs ala the early_printk serial drivers, but I think Alan Cox shot that idea down? Don't recall and the pages google's finding say netconsole just doesn't do early boot messages before interrupts are enabled, which is basically when it's about to launch PID 1 (interrupts = we can drive the scheduler now)...)

> Check /dev/sda1 if you want to see the uboot config.

With a serial console I could use u-boot interactively, and set up tftpboot and all that fun if I really wanted to (without even persistently changing the uboot config).

Some kernel developers won't touch a box without a jtag, but I'm the "stick printfs in everything" kind. With serial console you can get it down to two lines right at the start of "it's running code":

This example is missing the real-world "spin checking the ready for output bit in the status register" part, but you can usually track down the appropriate uboot serial output driver and figure out what your two lines are. Or break down and read the spec sheet. :)

Quiet hotel room without cats. I get so much more done here, even if at the moment it's still mostly just catching up on email...

January 21, 2018

So much fog approaching wisconsin. Stopped at a McDonalds for a couple hours to see if it would clear up, and it got worse instead. Oh well, got to catch up on some email, anyway.

I've recently noticed that "I've publicly said this 5 times" doesn't mean other people have heard it, so here goes again.

Speaking of which, it's possible the "minimal" system will grow a fifth required-ish package: cryptography. (Largely thanks to out-of-control state surveilance bureaucracies trying to endlessly expand their budgets.) If public key signing is required to verify package downloads (not just checkign a hash), or https:// downloading becomes necessary for the base OS build (we're flirting with that already), then that doesn't really belong in any of the above because "not leaking data through crypto side-channels" is its own area of expertise needing its own set of experts doing their own package.

Except... ktls is half a solution exported by the kernel already. It's possible some crypto is in scope for toybox (such as https) using ktls. Right now it's just half the plumbing and you need a big wrapper around a member of the openssl family to use the ktls plumbing the kernel provides, but maybe that's doable and/or less of an issue in future?

Encryption is not within scope for toybox because of the same zlib/curses problem: external libraries _must_ be optional so we'd need to provide a simple built-in version of their functionality, and I ain't rolling my own cryptography. (Hence wanting an stunnel style solution for wget and httpd forever, without which neither command is hugely worth doing...)

January 20, 2018

I stopped at a McDonald's in Texarcana to recharge my phone on the drive up to wisconsin, and I saw email from the manager from back when Large Phone Manufacturer That Still Wishes To Remain Anonymous sponsored some toybox work a few years back, and I accepted the link because for once it's somebody I actually know. (Well, we never met in person, but I sent her a lot of email.)

This opened linkedin, and one of the links on there was an incredibly vague position at... Google Austin. Which I found greatly amusing, and I almost tweeted "I really, _really_ shouldn't apply to this..." with a link, but it would require too much context to explain.

But "too much context for twitter" is what blogs are for. So:

Yes I just signed up for a 6 month contract in wisconsin (which I am driving to, so I'd have the car up with me), but last time I applied to google it took 8 months to work through their hiring process, so I wouldn't expect them to conflict. (Besides, given my previous experience with Google I wouldn't expect to _get_ the job, I'm mostly just amused.)

The _first_ time a Google recruiter called up and tried to hire me was over 15 years ago. (I took the phone call in the apartment I had when I worked at WebOffice, so 2001 or 2002.) I think I was on Google's radar because way back in 1999 when I wrote stock market investment columns the portfolio I covered included Yahoo, and I wrote an article mentioning I preferred Google's technology. And google sent me a t-shirt and a bunch of stickers, because they said it was their first stock market coverage. (This was 5 years before their IPO, they were still a "linux search" site in beta, I think I heard about 'em though slashdot. That's how long ago it was.) Or maybe the recruiter called me because of my posts to lkml, who knows?

I've never particularly wanted to move to California, although my reasons why (expensive and earthquakes) don't seem to apply to Tokyo for some reason. Huh. (At this point I suspect it's inertia.) But Google recruiters kept calling like clockwork every 6 months for the next few years.

Then ten years ago ChromeOS came out, which sounded like fun (this was _after_ I co-authored a paper on why Desktop Linux hadn't happened, so yay new approach with a hardware vendor behind it who could get preinstalls). So I followed Google's "apply to work on ChromeOS" link but selected the Dublin Office from the site selection pulldown because I'd never lived in Ireland and that also sounded like fun. This confused Google's hiring process (seriously, I break everything), so they didn't get back to me for a few months, but I was in the downtime between contracts and didn't mind. (Consulting meant I earned enough I could take time off between contracts, which is when I got most of my open source programming done. This is back before marriage led to big house and other people to support, or at least reassure that I know where the money is coming from next month).

Google's version of a cat's "when in doubt wash" seems to be "Site Reliability Engineer", which they could do in Dublin, and it sounded worth a try, setting off an odyssey of endless phone interviews, culminating in an all expenses paid trip to the Googleplex (my first time in Silicon Valley proper), and then deculminating in some sort of telepresence interview _after_ that in Google's Austin office (next door to Qualcomm, northwest corner of I35 and Mopac, and deserted except for a receptionist when I arrived) where somebody on the other end of a camera wanted me to write code in chalk on a blackboard. As I said, I confused them, and they spent a long time making up their mind...

Except they didn't. A full 8 months after I'd applied, when my bank account was getting kind of thin waiting for a decision (I'd have gone to work somewhere else months earlier but I was waiting to see what Google thought), they said I'd passed all the interview hurdles, my resume was sitting on the desk of whichever cofounder it was who personaly approved all hires, but the position I'd applied for had been filled and I needed to restart the process from scratch.

I thanked them for their time and got on with my life.

The next google recruiter to call me 6 months later was confused about my status in their HR system. I explained my Interview Odyssey and resulting reluctance to reopen that can of worms, she put a note in my file, and they stopped calling for a while.

Shortly after I did my 2013 toybox talk about hijacking android for my own purposes to steer the computer industry, I got a call from another google recruiter (no, he hadn't seen my talk) and went "ok, why not" and went through the thing again, except I'd just finished up my 6 month contract at Cray in Minnesota an was spending a week with my sister and her 4 children before returning to Austin, and hanging out with small children exposes you to every stomach bug they pick up at school, so I had to cut the interview short to urgently visit the bathroom, and the Google guys decided _not_ to continue, an I went "ok" and got on with my life. Haven't heard from a google recruiter since.

Google merged toybox in 2015 and has been using it since, but toybox development's stalled badly as SEI struggled to stay afloat. As the company lost staff instead of staffing _up_ we all wound up doing 4 jobs apiece (the corollary to Brooks' Law I learned at timesys remains true, removing people from a project is as big a delay as adding them, you spend all your time on "knowledge transfers" and then the remaining people have to come up to speed on tasks the departed used to do) and the stress started affecting my health.

At the start of the year I went "this is the _second_ set of taxes I'm going to have to check my bank statements to see which paychecks they managed to make, _after_ dropping us to half pay", and when a recruiter offered me twice what SEI had paid back when we were full-time (so 4 times now even if they _did_ make every scheduled paycheck) I took it. (The email I got from Elliott talking about "the thing that replaces toybox" helped with my decision to sign the contract. The advantage of a 9-5 job in an office is you know when you're _not_ working, and can do open source stuff without guilt...)

I was tempted to apply to the linkedin thing in part because the idea of using Google's "20% time" to work on toybox was just too ironic. Google's never paid me a dime for toybox. Elliott bought me lunch once. And they gave me an "open source award" (along with a dozen other people) that came with a $250 gift card, but I had to go to payoneer's website to activate the card and the login credentials they sent me didn't work. I even poked the Google open source award coordinator to confirm the credentials, but never could log in and after enough failed tries it disables itself. (I still have the card in my wallet, probably expired by now.)

And yes, I'm aware 20% time no longer really exists, that's a whole 'nother rant (that links to December 1 but the topic continues through december 2, 4, 5, and 6, I should collate old blog entries into proper writeups someday. My todo list runneth over. I prepared and presented a proper talk on that topic at Flourish last year, but they never posted the recording.)

Anyway, the bit about the google job is moot because when I clicked through it went to an application page on (with the same info), and when I clicked on "apply" there Chrome gave an error page because the site "redirected me too many times". (I repeated this 3 times to be sure it wasn't transent, then got on with my life.)

I break everything. And I continue to confuse Google's recruity-bits.

Anyway, back on the road to Milwaukee.

January 19, 2018

Finally finished flushing the lkml and qemu-devel folders into "2017" sub-folders so thunderbird doesn't choke on the giant mboxes bigger than it can handle (making email download sit there and twiddle its thumbs for a couple minutes when the filters try to move the first message into that folder, sometimes making the smtp server time out).

And this meant I started reading qemu-devel at the start of january, and noticed Laurient Vivier pushing his m68k support patches again. Looks like seriously this time. (Yay!)

So I wander to my qemu directory, make sure it isn't locally patched (git diff), do a git pull, start to ./configure, kill it and do a make clean just in case, and...

$ make clean
  GEN     aarch64-softmmu/config-devices.mak.tmp
  GEN     aarch64-softmmu/config-devices.mak
  GEN     arm-softmmu/config-devices.mak.tmp
  GEN     arm-softmmu/config-devices.mak
  GEN     i386-softmmu/config-devices.mak.tmp
  GEN     i386-softmmu/config-devices.mak
  GEN     ppcemb-softmmu/config-devices.mak.tmp
  GEN     ppcemb-softmmu/config-devices.mak
  GEN     x86_64-softmmu/config-devices.mak.tmp
  GEN     x86_64-softmmu/config-devices.mak
  GEN     config-all-devices.mak
config-host.mak is out-of-date, running configure

And so on and so forth. It generated dozens and dozens of config-target.h and blah-commands.h files just so it could delete them!

Meanwhile, "git clean -fdx" took like 2 seconds. Except for the part where .gitinfo can tell it to ignore files which don't get deleted, and I'm reluctant to try to add options to override that because qemu uses subtrees for dtc and stuff and I don't want to delete them.

Projects seem to have a natural lifecycle where they get so complicated fewer new developers come on board, and eventually they starve for resources when the existing batch ages out. The average age of linux developers is Linus's age, and he's something like 47 now...

January 18, 2018

I have a failure mode during software development, which is naming stuff strangely. I had to do a cleanup pass removing the "9 princes in amber" references (a book series by Roger Zelazny) because after enough repetitions of the variable "pattern" I threw a "logrus" in there in self-defense and it spiraled from there.

Now I'm cleaning up ps, which has -o fields living in "struct strawberry" with the variable length char array at the end of course called "forever". This doesn't help anyone understand the code.

I'm banging on gzip right now and resisting calling the --rsyncable option --titanic during development.

All this should have been cleaned up and properly explained long ago, I've just been so drained trying to keep SEI afloat. And now I'm packing to move to Wisconsin for half a year.

January 17, 2018

The reason "sudo echo 0 9999999 > /proc/sys/net/ipv4/ping_group_range" doesn't work is the shell opens the redirect file before calling sudo, which means it does so as your normal user. Alas putting quotes around the sudo arguments doesn't work because it doesn't re-parse the command line so tries to run a single command with spaces and a > character in it.

This is why I wind up doing sudo /bin/bash a lot.

January 16, 2018

Youtube cut off monetization of channels with less than 1000 subscribers. It's the hobbyist->employee->bureaucrat progression again. I should really give a proper _recorded_ version of that talk somewhere.

I gave it at Flourish. I was prepared, reasonably well rested, and gave a version I was proud of. They recorded it. The recording never went up. There is very little a conference an do to annoy me more than _promise_ to post a recording of a talk and then _not_ do it. Sadly common problem: Flourish screwed up the recordings both times I went there, LinuxCon Tokyo 2015 had a video camera that apparently wasn't on, Ohio LinuxFest pointed a video camera at me and then only posted audio....

Penguicon failing to record Neil Gaiman's "crazy hair" reading after which I got him to say "By Grabthar's Hammer, You Shall Be Avenged" into the microphone with NO TAPE IN THE MACHINE was the Science Fiction Oral History Society's fault, but it was at a conference I co-founded so that makes it my fault. I added a "new thing" to each year of Penguicon (year 4 was LN2 ice cream, we dumped the extra LN2 into the swimming pool sunday afternoon), and year 3 (I think?) I bought 5 MP3 lecture recorders with a promised 12 hour battery life and taped them down to the tables in each panel room. No idea what's happened to that since Matt Arnold drove away all the people who used to run it, I haven't been back in 10 years...

January 15, 2018

Ok, fixing ps -T. If I go "ps -AT" I get 13 hits for chrome (pid 1401 and 12 threads). But if I go "ps -T 1401" I get just one hit (pid 1401, no threads).

And done. The /proc layout repeats the thread under the pid, so /proc/123 will have all hte process information for the parent, and then there's a /proc/123/task/123 that _also_ has it. There's a check to notice that and skip it when we're parsing threads, which was supposed to copy the parent pid into the child's PID slot when it doesn't skip it.

I.E. if the parent->PID and my->TID were equal, return. Else my->PID = parent->PID; The else bit was missing.

January 12, 2018

Signed the contract for the new job. I need to be in Milwaukee by the 22nd.

My next choice is do I drive up or fly up? I have southwest credit from cancelling my return flight from ELC last year (work flew me from LA straight to Tokyo instead, yes those trips were always on that short notice), and if I don't use that it expires soon. But if I drive up I'd have the car with me and can drive to see Fade on weekends. (It's a little under 5 hours drive each way, reasonable to drive up friday after work and drive back sunday evening. Flying each way probably takes _longer_ if you add in getting to the airport, through security theatre, and then public transit through minneapolis.)

Decisions, decisions...

January 11, 2018

I tried -rc7 in mkroot. The arm build grew a perl dependency again. The x86-64 build died because it couldn't find an ORC unwinder. Wheee!

New battery arrived! It's 6 cell rather than 9 cell but hopefully that means it's less fragile. (I ordered 2 9 cell batteries and wound up breaking both, they stick out awkwardly as a sort of footrest leaving the keyboard at an angle and only letting the screen fully open if everything aligns exactly. The 6 cell ones I've never broken (just worn out) and I can almost lay the screen flat back.)

Downloading email is _so_ much faster now I've cleaned out LKML. I'm still shoveling out qemu-devel, and then buildroot's got over 100k messages in it that should probably get moved out of the folder my mail filters are dumping new messages into. (You can have an enormous mbox that doesn't get USED during download and it won't slow down email downloading.)

Yes, this is related to the "I have to download from gmail via pop because imap is far more broken".

January 10, 2018

Met with the recruiters for the new job, picked up the pile of paperwork to sign. Feeling kind of morose, like I'm letting SEI down.

I've spent 3 years working for Jeff, which I think is longer than I've been at any other job. (Even beat out my first job at IBM by a few months.) I believe in what SEI's trying to do, and stayed a year and a half longer than they could reliably pay me, and I'd happily go _back_ there after this contract... if there's anything left. Jeff insists that there's a new contract coming soon that gives us a change of direction and fresh funding, except the fix for everything has been Real Soon Now for 2 years. This is the THIRD set of investors that have deliberated at length about giving us money. The stress is killing me, I need a break.

Alas, you can't fund from operations targeting utilities without bootstrapping to a large size and going through standards compliance nonsense. To get around that Jeff parnered with a big company that screwed us over for internal big company political reasons, and then he tried to put together a funding round based on another big company that was once _again_ paralyzed by big company internal politics. Disruptive technology 101: a large existing corporation cannot commercialize anything new in-house, it can only buy it once it's already proven.

This is not on the tech side of the house, I dunno how to fix it. Make a product and sell a product to people who will use the product I understand, navigate corporate status/dominance games where everything is some shade of affinity fraud and nobody involved in the decision making will be personally affected by the outcome except politically... that's not a domain I've spent a lot of time building skills in, because I sympathize with the people polishing guillotines every time it comes up. During the entire "postwar booom" period the top tax rate in the USA was 91%. (In 1963 they lowered it to 70%. Reagan lowered it to 28%, at which point our deficit exploded and corporations stopped investing in anything. Taxing profits makes companies spend money on research and training and all sorts of things that won't impact next quarter's numbers but are better than seeing the money confiscated by the feds. Lowering taxes makes them stop making any long-term investments in their business, their fig leaf being they can pile up cash and buy some other company that did all the right things later, the reality being they legally embezzle it all. Why is this hard to understand? This guilded age royal court nonsense is a _sickness_. It is symptomatic of an unhealthy economy, these are parasites feasting.)

Sigh. Happier thoughts.

My sad little netbook is plugged into wall current. It'll run without a battery, but isn't happy about it.

Thunderbird's terrible at dealing with large mbox folders, where large" is "a year of linux-kernel or qemu-devel". So I've created "lkml-2017" and "qemu-2017" subfolders and am once again copying all the year's messages into them and compacting stuff. It's REALLY slow.

You click on the first message, scroll down to the end of the range you'd like to copy (too much and it triggers the OOM killer, I can get away with maybe 20k each pass), shift-click on the ending message, then wait multiple minutes for the highlight to happen, then right click on any of the highlighted messages and wait the same amount again for the pop-up menu to appear, then navigate to the folder you want under "copy to->", click, and go to lunch.

If you've highlighted more than about 25,000 messages the copy will complete (and it deletes them as it goes), but afterwards thunderbird does some insane processing that exhausts all memory, drives the system into swap, and eventually triggers the OOM killer to kill thunderbird. (That's assuming you don't think the system is hung because your mouse cursor takes 3 minutes to respond to attempts to move it.)

If it's less than 25k messages it just takes forever to complete. As in I went to the grocery store and it wasn't done when I got back. Did I mention 25k messages is maybe 2 months of lkml traffic? It's something like 350 messages a day, plus bursts of ignorable bot-generated nonsense. (Your patch failed to build against the -tip tree! Why are you mailing the list? The giant backports against -stable patch series need their own list, but nobody would read it, so...)

Mostly I read the web archive, but I need the messages to reply to.

January 9, 2018

Dropped Fade and Adverb off at the airport. New semester starting, she's going back to her dorm in Minneapolis.

Sigh. LWN's is it time for open processors article (in response to meltdown and spectre) doesn't even mention of j-core. It mentions openrisc, and clones of powerpc and sparc, and links to riscy's press release. I guess we look too dead to matter.

(I _cannot_ get excited about RISC-V, it strikes me as Open Itanium. They promised everything to everyone and are cashing very large checks, and I see no obvious reason for it to displace x86 or arm? And that's _with_ meltdown and spectre. Maybe china will standardize on it by fiat, but didn't they already try that with a mips fork?)

Of course j-core's still a nommu processor, so you don't _need_ a memory protection bypass because there's no protection to bypass, but... Rich hasn't posted to the linux-sh list in months, and it has an outstanding futex bug for how many releases? QEMU's sh4 serial console's been broken for ages and still not fixed? Our last VHDL code release tarball was 2016 (did that support SMP? I don't remember). We never got even _part_ of the VHDL code up on github...

Jen says that Jeff had a good meeting with the new investors yesterday, but they didn't sign a check at the meeting. Just like we didn't get actual money from the december meeting, or the november meeting, or the october meeting. Not even the money for the "statement of work" that was supposed to tide us over until the end of last year. (I.E. it's a quarter's worth of money we've already spent a quarter trying to get.)

I can't make this happen by myself.

Heard back from the recruiter about the Milwaukee gig. They want me, but the recruiter was trying to talk down my quoted hourly rate at the last minute? Confused.

I had my netbook closed on a bench, it fell off about a foot onto a tile floor, and the battery case cracked in 3 places. Wheee. The screen no longer opened because it was hitting a piece of cracked battery case, and pulling it off took off about half the plastic.

Running it without a battery right now. Fade's ordered me a new one. (Did I mention I know too much about how the sausage is made to be comfortable typing my credit card info in to a website _ever_? I'm aware having someone else on a joint bank account do it does not improve matters, and yet.)

January 8, 2018

And my netbook finally rebooted. I tried to reproduce a mkroot issue which meant a script ran oneit as root, which couldn't attach to the requested console, and on the way out it rebooted the system.

Todo item: fix that.

January 7, 2018

I've found the jpop group responsible for Miss Kobayashi's Maid Dragon's opening and closing music. It is All The Bouncy.

Appending it to my normal music playlist put it right after Demi Lovato's cover of "Take me to Church" and the switch between the two has gears grinding.

Listening to colorado video about demand charges being one of the big drivers for pairing battery walls with solar and going for "complete curtailment". I.E. collect extra solar in your battery wall, and when your batteries are full just switch off the solar panels. Never try to feed anything upstream into the electrical grid. Apparently getting to 80% of this is easy, getting to 100% is hard.

January 6, 2018

Fade took me to Dead Lobster, by which I mean I drove and she paid. Took the hybrid loaner car, which remains deeply shiny. I looked up its price (they're so clearly letting my use this thing as a form of advertising) and it's $29k. That's for last year's model, not the new one. It's not outside what I could afford, but it's outside my comfort zone.

When I was 7 years old I got all excited about the idea of compound interest, and was pretty sure I could retire at 30 (or at least get to the point where I earned more in interest than in paycheck), and I was on course to do that circa 1999 or so (earning $50/hour and offered $75/hour to stay, plus owned two condos that went up $20k each in price while I owned them, not bad for a 27 year old), but over the years instead of saving and investing I gave time and money to friends and family in need. I'm doing ok, but I'm not close to retired.

Take SEI: I've been on half pay there for a year and a half, and they haven't even made those reliably. They're making about 2 out of 3 paychecks these days, which means I'm down to 1/2*2/3 = 2/6 = 1/3 pay which is not sustainable with this house even without the flooding. And that's on TOP of the fact I could make twice that fulltime hourly rate if I went back to consulting, so I'm choosing to earn 1/6 my market rate. I don't care about money, but I do care about a _lack_ of money, and things like social security and medicare won't survive the GOP, so I need to provide for my own retirement. After ten years of marriage Fade's never had kids so I'm pretty sure that's not happening at this point, and she's up in Minnesota, so I might as well go back to the Lucrative Nomad lifestyle before age discrimination kicks in too hard. (It's easy to find work if you go where the work is and do what they pay you to do. I've worked from home on stuff I find interesting, but the stress is getting to me.)

At the start of the new year I decided to look around. I did a phone interview for a gig in Milwaukee on Thursday, and I'm told I'll hear back on that Monday. I very much want to see SEI succeed but I can't make customers pay their bills or investors follow through on their promises, and they're not really sponsoring toybox development anymore...

I got a reminder about the CELF deadline (which has been extended to tuesday). Do I want to commit to travel at this point? Hmmm...

Where did I leave off... ping.c! (Although if I'm to make proper use of that cortex-m board before innoflight asks for it back again, I should do tftp/tftpd since that tftpboots.)

I need to check timestamps in fractions of a second, and I vaguely recall I created a millitime() function which returns current time in milliseconds (for the pun if no other reason: it's millitime). But it's not in lib, it's in ps.c, which means I have a second file wanting to use it so I should move it to lib/lib,c, and looking at that I trivially cleaned up the last function there, environ_bytes(). Except that function should really take environ as its argument, and thus be able to iterate over argv[] too. But I shouldn't go down that tangent just _now_...

Hmmm, this implies that xparsetime() from yesterday should probably return milliseconds too. (When launching command line binaries, that's about the resolution you can expect. You need nanosecond accuracy for things like filesystem timestamps where you're reproducing a previous reading exactly, but not delta-from-current with pages faulted in from storage and a potential call to the dynamic linker in there before any of your code runs. Again, todo item for later.

Sigh. It would be nice if posix made proper use of C's object orientation. Specifically, in struct sockaddr and friends, wouldn't it be nice if:

struct sockaddr {
  short family;
  // whatever else

struct sockaddr_in {
  struct sockaddr sa;
  blah blah blah;

struct sockaddr_in6 {
  struct sockaddr sa;
  blah blah blah;

Right now you can typecast either to struct sockaddr and works fine, but it's not obvious what portion of that you can use. With the above you could &(sockaddr_in->sa) and not even have to typecast. (You'd still have to typecast it back once you knew what the type was, the pointers will be the same because a pointer to a struct is a pointer to the first member of the struct, there can be no padding or alignment space at the beginning. But right now it's implicit, not explicit, and if I declare a function to accept "struct sockaddr *" you have to typecast to call it with sockaddr_in or sockaddr_in6. At which point it might as well just be a void *, because that's what I'm going to typecast it TO to make the compiler shut up.)

There are ways to declare your data so "I know what I'm doing, let me do it" does not require hitting the compiler with a rock, but the network stack doesn't do it that way.

(But no, people think you need C++ for that kind of thing. You very much don't. C++ only makes things worse. Because they don't teach how to do it right, and the berkeley guys especially spent their first decade doing CRAZY THINGS. Everything's a file... except network interfaces, those aren't. Ken and Dennis were very good at finding the "sweet spot" between not enough capability and too much complexity, and I greatly admire what they accomplished. Many of their successors in BSD and AT&T, not so much...)

January 5, 2018

Cycled back around to ping. Specifying time between ping instances means you do fractions of a second, but I'm trying to restrict the use of floating point in the code and keep it under #ifdefs (to work on really tiny systems). So my infrastructure for that is xparsetime() (originally for sleep) which returns seconds and fractional seconds in two longs, and only uses floating point when the ifdefs are defined.

I want to add -i, which needs fractional seconds, and at the moment that means I need to turn its optargs from a number to a string (# to :) and call xparsetime() on the string myself. That raises the question of whether I should do the same for -s and -W, so the time parsing is consistent. But neither of those particularly care about fractional seconds, and the OTHER thing the optargs number parsing does is range checking and default value assignment. Having to do that manually raises the expense a bit.

Speaking of range checking, if you _do_ feed a negative time to xparsetime() the non-float path errors, and the float path returns the negative value, except if it's -0.5 then you have to check the seconds and fractions seperately to catch that it's a negative value, and really I should just check it in the strtod path. Alas, then it needs another error message which seems wasteful. Also strtod() can skip arbitrary spaces and allows a + at the front so checking for - at the start is more complicated than it seems... (So many corner cases.)

I could add an xparsetime() type to lib/args.c but there aren't realy enough users to justify it? The other big one is sleep, but there it's an optarg, not a flag argument, so sleep_main() has to parse it anyway, and in GLOBALS it would still have a sizeof(long) slot needing to fit 2 fields, and a struct that fits in 32 bits on 32 bit systems would have to be 2 short ints so it couldn't do nanoseconds, which eliminates about half the other uses.

Ah, I see: if you go "sleep -1" it says 1 is an unknown option, that's probably why I didn't care at the time. Of course you can do "sleep ' -1'" and strtod() eats the leading space and then parses it and returns a negative number, although sleep then returns immediately so it doesn't hurt anything...

Sigh, ok. Keep -w and -W doing the optargs # integer parsing, and have -i do something different.

January 4, 2018

All the bugs in the world. I updated my offline backups.

Wouldn't it be nice if we had an organization like the NSA that was supposed to find and publish the sort of vulnerabilities that make Hardison from Leverage or Finch from Person of Interest's ability to hack into any computer anywhere NOT FICTION? Instead of hoarding them so it can keep their budgets unlimited in perpetuity by blackmailing future politicians with the porn they browsed as teenagers, and treating any other possible use of the data (such as law enforcement) as compromising their sources? Wouldn't that have been nice.

I know it sounds crazy blaming those sorts of guys for vulnerabilities that go back before September 11, 2001. But we know they're _trying_, the counter-argument is they're not as _effective_ as they'd like to be.

January 3, 2018

The Call For Papers deadlines for both ELC and TXLF are coming up. I'm still sort of "too tired, dowanna travel, I should just podcast", but at the same time I should show the flag and I do have various things I should probably talk about: 0BSD and licensing stuff, mkroot, making android self-hosting... Heck, I could do a panel of just war stories. Haven't bothered to write up any proposals yet though.

Dropped the car off at Howdy Honda. In addition to the crunchy noises from the suspension when it hits uneven road (cv joint?), it's now making growling noises when it's cold and you turn the wheel. (Power steering pump?) It's a 2002 car, about 16 years old now (we bought it used). I've been waiting for app-summonable self driving car services, but that's like 2 more years for early adopters and maybe 5 to be ubiquitous in urban centers. (And in about 7 gasoline volume declines enough that the profit marging for refining, distributing, and selling it with the current infrastructure and transportation network goes negative, at which point a car running on gasoline isn't quite so useful. And yes the auto industry knows this so resale value's likely to decline well before then, but "when does the herd break and run" is always a hard financial question. All the manufacturers are switching over to electric cars now, but the first generation models are still too expensive for my tastes and when the self-driving subscription fleets show up why own your own? Don't sink a well when city water's 5 years away from reaching your neighborhood...)

So yeah, waiting out the awkward adolescence of yet another industry. I rememer the days of "when can I get an ISP instead of dialing in to my university or work", "when can I get broadband instead of dialup", "when is my cell phone good enough to stop paying for a landline", "should I just have a laptop and not bother having a desktop", "when can we switch from netflix mailing us DVDs to just the streaming", "hard drive or ssd"...

These days there's "when to get rooftop solar and a battery wall", "when can I get a development environment on my phone/tablet so I don't need a PC anymore"... There's usually some case where :I know where it's GOING but is it quite HERE yet", and a car is a large purchase that kind of imposes itself upon you at times...

January 2, 2018

Jeff just asked me to work on an 8-bit chip design with him, but I'm already stretched too thin on the stuff I'm already doing. The Big Push in november involved GPS, helping arrange investor meetings, trying to track todo items for the whole company, turtle manufacturing stuff, and of course the endless uncertainty. (During investor prep Jeff kept gaming out how the bloq guys might screw us over or flake, so we'd be prepared. About half the time I didn't know where I'd be sleeping the next day.)

Jen not showing up wasn't Jeff's fault but it meant plans changed and I had to try to figure out what Jen does and maybe try to come up to speed on the existing customer phone calls (maintaining their trickle of R&D funding) and see if Weekly Engineering Call With Jeff could replace Daily Engineering Call With Jen if she flaked completely. That's a management job I got sucked into a vacuum for.

Jeff tried to sit me down and teach me enough VHDL to help with the ASIC tapeout, despite niishi and arakawa with years of experience in it _not_ being up to help with the tapeout. He tried very hard to get me to track what RiscV was doing and I _cannot_ bring myself to care, it smells too much like an open source version of Itanium made from hype and overcommitted promises and absorbing all the funding in the world to be less interesting than x86, let alone arm. We met with a nice lady at a university who's doing a toy processor. We sat down to try to sort the instruction bit patterns of j-core so we could redo the front end more efficiently, but didn't have time to finish that. We started to triage the build system for a github release, but didn't have time to finish that. We talked about hooking up the GPS-stabilized nanosecond accurate clock to the userspace signal monitoring package, but didn't have time to finish that...

All this has put me way over mental budget on my normal ecosystem (which used to be aboriginal linux+busybox and is now toybox+mkroot/aosp). Trying to turn android into a self-hosting development environment is STALLED HARD. (Politics: the pixel 7 tablet is discontinued so all the google in-house testing systems are now chromebooks; chromeos runs android apps but what does this mean for testing android base layers? How is development shifting inside google? I haven't had a chance to ask. Whatever it is is happening without me and I'll find out 6 months later when it's too late to provide feedback that might influence any of the decisions. Oh well.)

I haven't done half of what I need to on SEI's Board Support Package because that hasn't really been my job in forever. The website is in pieces and the mailing list is silent because I'm not sure what I'm allowed to _say_. The website needs to turn into kernel Documentation/ files. The arch/sh and linux-sh stuff is badly stale upstream and in _theory_ that's Rich's task but in practice he hasn't got cycles for it (and he only cares about testing on real hardware, even though QEMU is what the upstream kernel guys can actually regression test against; the serial console's been broken for most of a year and we never fixed it translates to a perception that "this platform is dead"). I haven't kept up with new kernel developments in general for the quarterly releases, and I've had patches I've wanted to push upstream for a year, but haven't.

I have a significant issue that that my own projects look dead to other people. I haven't posted to the mkroot list since October. I spent some time getting mkroot closer to parity with aboriginal in terms of supported targets (the reboot was required by swapping out the toolchain for musl-cross-make) but I still haven't got the native toolchains working, let alone the distcc trick or the build control image automation layer. The last mkroot release was in June, using a 4.11 kernel (which is over a year old now).

I spent part of this vacation getting my technical development blog caught up closer to current, which means I've gotten it up to mid-september. (I have daily-ish rough draft notes-to-self in a text file but it needs significant editing and expansion to make sense to anyone else. Plus html tags and links and proofreading.)

I've spent the rest of this vacation trying to do enough toybox work the project doesn't look dead to the android guys. I got the smallest two commands promoted out of pending and I'm trying to deal with the new submission of fmt.c (from the android guys).

I'm sitting on the west coast Embedded Linux Conference call for papers and haven't submitted anything yet because I'm _tired_. It would be really good to show the flag there but my talk there last year and the one before that at were incoherent because I was too exhausted to prepare and give good talk. (And given my baseline fatigue and redeye flights one day was NOT enough to recover from jeglag in either case.) It hasn't gotten better since.

It looks like I can either stop doing open source development, or I can get a day job doing something less taxing which I can stop thinking about when I leave the office.

Sigh. Jeff talked about how great sitting down and grinding is, and I WANT to do that but I CAN'T because it's a constant stream of interruptions swap-thrashing between too many projects that never produce output and idle for so long between bursts that when you go back to them you spend all your time trying to figure out where you left off and why because you've forgotten all the context and have to reverse engineer your own code. This has been the failure mode of toybox development for the past couple years, now it's becoming the failure mode of EVERYTHING, because I can't focus and when I do carve out time I'm too exhausted to make good use of it.

Random example: waiting at the airport for the flight back from tokyo, I caught up another couple weeks on the j-core news page. Triaged, edited, and uploaded. Haven't touched it since, so of course it's now further behind than it was when I did that. And of course there's no https on that website even though doing so is like half a day's work. (Well, for Rich. Probably about 3 days for me, the update scripts are fiddly and there's a dozen implementations with no obvious winner because the one Let's Encrypt provided/recommends is overcomplicated crap so many people have made their own but _because_ there's an "official" one none of the others has coalesced a big community around it yet and become the obvious one to use.)

I remember when Jeff and I talked about moving all the servers to tokyo. A year or so back, we bought a USB drive to do backups to, and he had me install ubuntu on an old 32-bit machine he had lying around. Might have been the end of the trip with Tokyo Big Sight?) Out of curiosity I just ssh'd into and did a sudo aptitude update and it has 58 packages it wants to upgrade. I'm afraid to do the corresponding upgrade because if it breaks, what do I do? The person Jen tried to transfer wale's sysadmin responsibilities to was... me. The servers are in the back of an office in canada, I'm in texas.

I'm not sure I'm still making a difference here.

January 1, 2018

Happy new year.

Next low hanging fruit pending command to clean up, sorting by source file size, is logger.c. The main reason it's in pending is it depends on CONFIG_SYSLOGD. That kind of cross-command dependency is unpleasant, I try to either merge them into the same .c file (ala ps/top/pgrep) or move whatever they share to lib.

Since the actual function logger wanted out of syslogd was only a few lines long, I just inlined it in the two calls in logger, did the other obvious cleanups, and tried a test build... at which point I noticed the next problem.

The function I inlined is iterating through two arrays, facilitynames and prioritynames, which are defined in sys/syslog.h. But you have to #define SYSLOG_NAMES before #including that in order to get them. Why? Because #ifdef in the header is instantiating the array, which means if you #include it from two places you get two copies of the array.

The really STUPID part is I can't #include it from one file and then extern reference it elsewhere because the TYPE is defined in the same #ifdef.

One of Rich Felker's coworkers complained about this before, and clearly this was a case of glibc being stupid, but it's one of those things that shipped and now fixing it would break existing programs.

Back to 2017