Firefighters fought to maintain the upper hand on a rapidly moving wildfire that swept through rugged mountains north of Los Angeles.