20070731 tech: Sun Micro swings to profit