Manumission wasn't *discouraged* in Alabama and other states. Regulated would be a better word. State law placed requirements on any slave owner who desired to free his slaves to be sure that freed slaves didn't represent a nuisance or burden to other citizens.
Consider that 2,690 free persons of color represents less than .0028 of the total state population of Alabama in 1860 (964,201). Then recall the exception made for free persons of color (Creoles) covered by treaties with Spain. About half the free persons of color reported on the 1860 census lived in Mobile (1,195) and Baldwin (140) Counties. The other 48 counties averaged 28 free colored persons each. If we strike counties having large urban centers -- Madison (192) , Montgomery (70), Dallas (80) and Tuscaloosa (84) -- the average falls to 21, or three households per county.
My post was based on the Alabama Code of 1852. As tensions increased up to 1861, laws governing slavery and free persons of color became more restrictive.
During the 1850s state law in both Alabama and Indiana had similar laws governing residence of free persons of color. Both encouraged them to leave ASAP. For example, a white citizen in Indiana attempting to help a free person of color to establish residency was subject to a heavy fine. In the Lincoln-Douglas debates, both candidates make it clear that the territories should be open to free *white* settlers and no one else. That's one reason why Whigs like Henry Clay, Abraham Lincoln &c opposed the acquisition of any more Spanish colonial possesions in America -- people of "mixed blood" would become citizens of the United States.
Two words explain the change in attitude after 1830 -- slave rebellions.
The Nat Turner uprising in August 1831 marked a significant turning point for Southerners. We just passed the 150th anniversary of John Brown's attempt to incite a major slave rebellion on Southern soil. That and subsequent events -- the discovery of Brown's papers and maps; proof connecting him to prominent abolitionsts who supplied guidance, cash and arms; expressions of public sympathy in the North for Brown; the Senate investigation of Harpers Ferry chaired by Jefferson Davis -- led directly to secession of the Southern states.