A vineyard on a hillside needed a wall around it to prevent soil erosion and to keep out the cattle that would otherwise trample the vines. The wall also had to keep out the wild boar, a large and agile tusked animal which could obliterate an entire vineyard. The destruction wrought by wild boar is an apt metaphor to use to describe the terrible atrocities committed by the Assyrians.
Still, the psalmist did not focus on the Assyrians but on God. God himself had broken down the protective wall around Israel, allowing neighbouring states to plunder and destroy.
12 Why then have you broken down its walls, so that all who pass along the way pluck its fruit?