Honda is recalling 1.5 million cars and crossovers to reprogram the transmission control software to prevent damage if the automatic transmission is used to rock the vehicle out from being stuck in mud or snow.

The recall covers the Accord and the CR-V and Element crossovers from the 2005 through 2010 model years. The vehicles being recalled have four-cylinder engines.

Honda says quickly shifting the transmission among drive, neutral and reverse--which a driver would do in an attempt to free the vehicle from being stuck--can damage a shaft bearing in the transmission. A damaged bearing can cause the engine to stall or make it hard to put the transmission into park.

The software update will ease the transition among the gears, Honda said, and reduce the chance of damaging the shaft bearing.